|
| 1 | +/* |
| 2 | +Copyright 2023 The Kubernetes Authors. |
| 3 | +Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +you may not use this file except in compliance with the License. |
| 5 | +You may obtain a copy of the License at |
| 6 | +http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | +Unless required by applicable law or agreed to in writing, software |
| 8 | +distributed under the License is distributed on an "AS IS" BASIS, |
| 9 | +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 10 | +See the License for the specific language governing permissions and |
| 11 | +limitations under the License. |
| 12 | +*/ |
| 13 | +package io.kubernetes.client.simplified; |
| 14 | + |
| 15 | +import io.kubernetes.client.openapi.ApiException; |
| 16 | +import io.kubernetes.client.openapi.models.V1Deployment; |
| 17 | +import io.kubernetes.client.openapi.models.V1DeploymentList; |
| 18 | +import io.kubernetes.client.openapi.models.V1Status; |
| 19 | +import io.kubernetes.client.custom.V1Patch; |
| 20 | +import io.kubernetes.client.openapi.apis.AppsV1Api; |
| 21 | + |
| 22 | +/* |
| 23 | + * This class is used to overload the AppsV1Api class methods for Deployments. |
| 24 | + */ |
| 25 | +public class Deployments { |
| 26 | + private AppsV1Api api; |
| 27 | + Deployments(AppsV1Api api){ |
| 28 | + this.api = api; |
| 29 | + } |
| 30 | + |
| 31 | + public V1Deployment createNamespacedDeployment(String namespace, V1Deployment body) throws ApiException { |
| 32 | + return api.createNamespacedDeployment(namespace, body, null, null, null, null); |
| 33 | + } |
| 34 | + |
| 35 | + public V1Status deleteNamespacedDeployment(String name, String namespace) throws ApiException { |
| 36 | + return api.deleteNamespacedDeployment(name, namespace, null, null, null, null, null, null); |
| 37 | + } |
| 38 | + |
| 39 | + public V1DeploymentList listNamespacedDeployment(String namespace) throws ApiException { |
| 40 | + return api.listNamespacedDeployment(namespace, null, null, null, null, null, null, null, null, null, null, null); |
| 41 | + } |
| 42 | + |
| 43 | + public V1DeploymentList listDeploymentForAllNamespaces() throws ApiException { |
| 44 | + return api.listDeploymentForAllNamespaces(null, null, null, null, null, null, null, null, null, null, null); |
| 45 | + } |
| 46 | + |
| 47 | + public V1Deployment replaceNamespacedDeployment(String name, String namespace, V1Deployment body) throws ApiException { |
| 48 | + return api.replaceNamespacedDeployment(name, namespace, body, null, null, null, null); |
| 49 | + } |
| 50 | + |
| 51 | + public V1Deployment patchNamespacedDeployment(String name, String namespace, V1Patch body) throws ApiException { |
| 52 | + return api.patchNamespacedDeployment(name, namespace, body, null, null, null, null, null); |
| 53 | + } |
| 54 | +} |
0 commit comments