Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
Copyright 2024 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package io.kubernetes.client.openapi.apis;
import io.kubernetes.client.openapi.ApiCallback;
import io.kubernetes.client.openapi.ApiClient;
import io.kubernetes.client.openapi.ApiException;
import io.kubernetes.client.openapi.ApiResponse;
import io.kubernetes.client.openapi.Configuration;
import io.kubernetes.client.openapi.Pair;
import io.kubernetes.client.openapi.ProgressRequestBody;
import io.kubernetes.client.openapi.ProgressResponseBody;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import io.kubernetes.client.openapi.models.V1APIResourceList;
import io.kubernetes.client.openapi.models.V1CSIDriver;
import io.kubernetes.client.openapi.models.V1CSIDriverList;
import io.kubernetes.client.openapi.models.V1CSINode;
import io.kubernetes.client.openapi.models.V1CSINodeList;
import io.kubernetes.client.openapi.models.V1CSIStorageCapacity;
import io.kubernetes.client.openapi.models.V1CSIStorageCapacityList;
import io.kubernetes.client.openapi.models.V1DeleteOptions;
import io.kubernetes.client.custom.V1Patch;
import io.kubernetes.client.openapi.models.V1Status;
import io.kubernetes.client.openapi.models.V1StorageClass;
import io.kubernetes.client.openapi.models.V1StorageClassList;
import io.kubernetes.client.openapi.models.V1VolumeAttachment;
import io.kubernetes.client.openapi.models.V1VolumeAttachmentList;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class StorageV1Api {
private ApiClient localVarApiClient;
private int localHostIndex;
private String localCustomBaseUrl;
public StorageV1Api() {
this(Configuration.getDefaultApiClient());
}
public StorageV1Api(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public ApiClient getApiClient() {
return localVarApiClient;
}
public void setApiClient(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public int getHostIndex() {
return localHostIndex;
}
public void setHostIndex(int hostIndex) {
this.localHostIndex = hostIndex;
}
public String getCustomBaseUrl() {
return localCustomBaseUrl;
}
public void setCustomBaseUrl(String customBaseUrl) {
this.localCustomBaseUrl = customBaseUrl;
}
private okhttp3.Call createCSIDriverCall(V1CSIDriver body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csidrivers";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldManager != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldManager", fieldManager));
}
if (fieldValidation != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldValidation", fieldValidation));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createCSIDriverValidateBeforeCall(V1CSIDriver body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createCSIDriver(Async)");
}
return createCSIDriverCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
private ApiResponse createCSIDriverWithHttpInfo(V1CSIDriver body, String pretty, String dryRun, String fieldManager, String fieldValidation) throws ApiException {
okhttp3.Call localVarCall = createCSIDriverValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call createCSIDriverAsync(V1CSIDriver body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createCSIDriverValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcreateCSIDriverRequest {
private final V1CSIDriver body;
private String pretty;
private String dryRun;
private String fieldManager;
private String fieldValidation;
private APIcreateCSIDriverRequest(V1CSIDriver body) {
this.body = body;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIcreateCSIDriverRequest
*/
public APIcreateCSIDriverRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIcreateCSIDriverRequest
*/
public APIcreateCSIDriverRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldManager
* @param fieldManager fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. (optional)
* @return APIcreateCSIDriverRequest
*/
public APIcreateCSIDriverRequest fieldManager(String fieldManager) {
this.fieldManager = fieldManager;
return this;
}
/**
* Set fieldValidation
* @param fieldValidation fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
* @return APIcreateCSIDriverRequest
*/
public APIcreateCSIDriverRequest fieldValidation(String fieldValidation) {
this.fieldValidation = fieldValidation;
return this;
}
/**
* Build call for createCSIDriver
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return createCSIDriverCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
/**
* Execute createCSIDriver request
* @return V1CSIDriver
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public V1CSIDriver execute() throws ApiException {
ApiResponse localVarResp = createCSIDriverWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
return localVarResp.getData();
}
/**
* Execute createCSIDriver request with HTTP info returned
* @return ApiResponse<V1CSIDriver>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return createCSIDriverWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
}
/**
* Execute createCSIDriver request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIcreateCSIDriverRequest createCSIDriver(V1CSIDriver body) {
return new APIcreateCSIDriverRequest(body);
}
private okhttp3.Call createCSINodeCall(V1CSINode body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csinodes";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldManager != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldManager", fieldManager));
}
if (fieldValidation != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldValidation", fieldValidation));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createCSINodeValidateBeforeCall(V1CSINode body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createCSINode(Async)");
}
return createCSINodeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
private ApiResponse createCSINodeWithHttpInfo(V1CSINode body, String pretty, String dryRun, String fieldManager, String fieldValidation) throws ApiException {
okhttp3.Call localVarCall = createCSINodeValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call createCSINodeAsync(V1CSINode body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createCSINodeValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcreateCSINodeRequest {
private final V1CSINode body;
private String pretty;
private String dryRun;
private String fieldManager;
private String fieldValidation;
private APIcreateCSINodeRequest(V1CSINode body) {
this.body = body;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIcreateCSINodeRequest
*/
public APIcreateCSINodeRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIcreateCSINodeRequest
*/
public APIcreateCSINodeRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldManager
* @param fieldManager fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. (optional)
* @return APIcreateCSINodeRequest
*/
public APIcreateCSINodeRequest fieldManager(String fieldManager) {
this.fieldManager = fieldManager;
return this;
}
/**
* Set fieldValidation
* @param fieldValidation fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
* @return APIcreateCSINodeRequest
*/
public APIcreateCSINodeRequest fieldValidation(String fieldValidation) {
this.fieldValidation = fieldValidation;
return this;
}
/**
* Build call for createCSINode
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return createCSINodeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
/**
* Execute createCSINode request
* @return V1CSINode
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public V1CSINode execute() throws ApiException {
ApiResponse localVarResp = createCSINodeWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
return localVarResp.getData();
}
/**
* Execute createCSINode request with HTTP info returned
* @return ApiResponse<V1CSINode>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return createCSINodeWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
}
/**
* Execute createCSINode request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIcreateCSINodeRequest createCSINode(V1CSINode body) {
return new APIcreateCSINodeRequest(body);
}
private okhttp3.Call createNamespacedCSIStorageCapacityCall(String namespace, V1CSIStorageCapacity body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/namespaces/{namespace}/csistoragecapacities"
.replace("{" + "namespace" + "}", localVarApiClient.escapeString(namespace.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldManager != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldManager", fieldManager));
}
if (fieldValidation != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldValidation", fieldValidation));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createNamespacedCSIStorageCapacityValidateBeforeCall(String namespace, V1CSIStorageCapacity body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'namespace' is set
if (namespace == null) {
throw new ApiException("Missing the required parameter 'namespace' when calling createNamespacedCSIStorageCapacity(Async)");
}
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createNamespacedCSIStorageCapacity(Async)");
}
return createNamespacedCSIStorageCapacityCall(namespace, body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
private ApiResponse createNamespacedCSIStorageCapacityWithHttpInfo(String namespace, V1CSIStorageCapacity body, String pretty, String dryRun, String fieldManager, String fieldValidation) throws ApiException {
okhttp3.Call localVarCall = createNamespacedCSIStorageCapacityValidateBeforeCall(namespace, body, pretty, dryRun, fieldManager, fieldValidation, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call createNamespacedCSIStorageCapacityAsync(String namespace, V1CSIStorageCapacity body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createNamespacedCSIStorageCapacityValidateBeforeCall(namespace, body, pretty, dryRun, fieldManager, fieldValidation, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcreateNamespacedCSIStorageCapacityRequest {
private final String namespace;
private final V1CSIStorageCapacity body;
private String pretty;
private String dryRun;
private String fieldManager;
private String fieldValidation;
private APIcreateNamespacedCSIStorageCapacityRequest(String namespace, V1CSIStorageCapacity body) {
this.namespace = namespace;
this.body = body;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIcreateNamespacedCSIStorageCapacityRequest
*/
public APIcreateNamespacedCSIStorageCapacityRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIcreateNamespacedCSIStorageCapacityRequest
*/
public APIcreateNamespacedCSIStorageCapacityRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldManager
* @param fieldManager fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. (optional)
* @return APIcreateNamespacedCSIStorageCapacityRequest
*/
public APIcreateNamespacedCSIStorageCapacityRequest fieldManager(String fieldManager) {
this.fieldManager = fieldManager;
return this;
}
/**
* Set fieldValidation
* @param fieldValidation fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
* @return APIcreateNamespacedCSIStorageCapacityRequest
*/
public APIcreateNamespacedCSIStorageCapacityRequest fieldValidation(String fieldValidation) {
this.fieldValidation = fieldValidation;
return this;
}
/**
* Build call for createNamespacedCSIStorageCapacity
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return createNamespacedCSIStorageCapacityCall(namespace, body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
/**
* Execute createNamespacedCSIStorageCapacity request
* @return V1CSIStorageCapacity
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public V1CSIStorageCapacity execute() throws ApiException {
ApiResponse localVarResp = createNamespacedCSIStorageCapacityWithHttpInfo(namespace, body, pretty, dryRun, fieldManager, fieldValidation);
return localVarResp.getData();
}
/**
* Execute createNamespacedCSIStorageCapacity request with HTTP info returned
* @return ApiResponse<V1CSIStorageCapacity>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return createNamespacedCSIStorageCapacityWithHttpInfo(namespace, body, pretty, dryRun, fieldManager, fieldValidation);
}
/**
* Execute createNamespacedCSIStorageCapacity request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return createNamespacedCSIStorageCapacityAsync(namespace, body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
}
/**
*
* create a CSIStorageCapacity
* @param namespace object name and auth scope, such as for teams and projects (required)
* @param body (required)
* @return APIcreateNamespacedCSIStorageCapacityRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public APIcreateNamespacedCSIStorageCapacityRequest createNamespacedCSIStorageCapacity(String namespace, V1CSIStorageCapacity body) {
return new APIcreateNamespacedCSIStorageCapacityRequest(namespace, body);
}
private okhttp3.Call createStorageClassCall(V1StorageClass body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/storageclasses";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldManager != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldManager", fieldManager));
}
if (fieldValidation != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldValidation", fieldValidation));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createStorageClassValidateBeforeCall(V1StorageClass body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createStorageClass(Async)");
}
return createStorageClassCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
private ApiResponse createStorageClassWithHttpInfo(V1StorageClass body, String pretty, String dryRun, String fieldManager, String fieldValidation) throws ApiException {
okhttp3.Call localVarCall = createStorageClassValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call createStorageClassAsync(V1StorageClass body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createStorageClassValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcreateStorageClassRequest {
private final V1StorageClass body;
private String pretty;
private String dryRun;
private String fieldManager;
private String fieldValidation;
private APIcreateStorageClassRequest(V1StorageClass body) {
this.body = body;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIcreateStorageClassRequest
*/
public APIcreateStorageClassRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIcreateStorageClassRequest
*/
public APIcreateStorageClassRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldManager
* @param fieldManager fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. (optional)
* @return APIcreateStorageClassRequest
*/
public APIcreateStorageClassRequest fieldManager(String fieldManager) {
this.fieldManager = fieldManager;
return this;
}
/**
* Set fieldValidation
* @param fieldValidation fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
* @return APIcreateStorageClassRequest
*/
public APIcreateStorageClassRequest fieldValidation(String fieldValidation) {
this.fieldValidation = fieldValidation;
return this;
}
/**
* Build call for createStorageClass
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return createStorageClassCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
/**
* Execute createStorageClass request
* @return V1StorageClass
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public V1StorageClass execute() throws ApiException {
ApiResponse localVarResp = createStorageClassWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
return localVarResp.getData();
}
/**
* Execute createStorageClass request with HTTP info returned
* @return ApiResponse<V1StorageClass>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return createStorageClassWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
}
/**
* Execute createStorageClass request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIcreateStorageClassRequest createStorageClass(V1StorageClass body) {
return new APIcreateStorageClassRequest(body);
}
private okhttp3.Call createVolumeAttachmentCall(V1VolumeAttachment body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/volumeattachments";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldManager != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldManager", fieldManager));
}
if (fieldValidation != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldValidation", fieldValidation));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createVolumeAttachmentValidateBeforeCall(V1VolumeAttachment body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createVolumeAttachment(Async)");
}
return createVolumeAttachmentCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
private ApiResponse createVolumeAttachmentWithHttpInfo(V1VolumeAttachment body, String pretty, String dryRun, String fieldManager, String fieldValidation) throws ApiException {
okhttp3.Call localVarCall = createVolumeAttachmentValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call createVolumeAttachmentAsync(V1VolumeAttachment body, String pretty, String dryRun, String fieldManager, String fieldValidation, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createVolumeAttachmentValidateBeforeCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcreateVolumeAttachmentRequest {
private final V1VolumeAttachment body;
private String pretty;
private String dryRun;
private String fieldManager;
private String fieldValidation;
private APIcreateVolumeAttachmentRequest(V1VolumeAttachment body) {
this.body = body;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIcreateVolumeAttachmentRequest
*/
public APIcreateVolumeAttachmentRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIcreateVolumeAttachmentRequest
*/
public APIcreateVolumeAttachmentRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldManager
* @param fieldManager fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. (optional)
* @return APIcreateVolumeAttachmentRequest
*/
public APIcreateVolumeAttachmentRequest fieldManager(String fieldManager) {
this.fieldManager = fieldManager;
return this;
}
/**
* Set fieldValidation
* @param fieldValidation fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
* @return APIcreateVolumeAttachmentRequest
*/
public APIcreateVolumeAttachmentRequest fieldValidation(String fieldValidation) {
this.fieldValidation = fieldValidation;
return this;
}
/**
* Build call for createVolumeAttachment
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return createVolumeAttachmentCall(body, pretty, dryRun, fieldManager, fieldValidation, _callback);
}
/**
* Execute createVolumeAttachment request
* @return V1VolumeAttachment
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public V1VolumeAttachment execute() throws ApiException {
ApiResponse localVarResp = createVolumeAttachmentWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
return localVarResp.getData();
}
/**
* Execute createVolumeAttachment request with HTTP info returned
* @return ApiResponse<V1VolumeAttachment>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
201
Created
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return createVolumeAttachmentWithHttpInfo(body, pretty, dryRun, fieldManager, fieldValidation);
}
/**
* Execute createVolumeAttachment request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIcreateVolumeAttachmentRequest createVolumeAttachment(V1VolumeAttachment body) {
return new APIcreateVolumeAttachmentRequest(body);
}
private okhttp3.Call deleteCSIDriverCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csidrivers/{name}"
.replace("{" + "name" + "}", localVarApiClient.escapeString(name.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCSIDriverValidateBeforeCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'name' is set
if (name == null) {
throw new ApiException("Missing the required parameter 'name' when calling deleteCSIDriver(Async)");
}
return deleteCSIDriverCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
private ApiResponse deleteCSIDriverWithHttpInfo(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCSIDriverValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCSIDriverAsync(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCSIDriverValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCSIDriverRequest {
private final String name;
private String pretty;
private String dryRun;
private Integer gracePeriodSeconds;
private Boolean orphanDependents;
private String propagationPolicy;
private V1DeleteOptions body;
private APIdeleteCSIDriverRequest(String name) {
this.name = name;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCSIDriverRequest
*/
public APIdeleteCSIDriverRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCSIDriver
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCSIDriverCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
/**
* Execute deleteCSIDriver request
* @return V1CSIDriver
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public V1CSIDriver execute() throws ApiException {
ApiResponse localVarResp = deleteCSIDriverWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
return localVarResp.getData();
}
/**
* Execute deleteCSIDriver request with HTTP info returned
* @return ApiResponse<V1CSIDriver>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCSIDriverWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
}
/**
* Execute deleteCSIDriver request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return deleteCSIDriverAsync(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
}
/**
*
* delete a CSIDriver
* @param name name of the CSIDriver (required)
* @return APIdeleteCSIDriverRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public APIdeleteCSIDriverRequest deleteCSIDriver(String name) {
return new APIdeleteCSIDriverRequest(name);
}
private okhttp3.Call deleteCSINodeCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csinodes/{name}"
.replace("{" + "name" + "}", localVarApiClient.escapeString(name.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCSINodeValidateBeforeCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'name' is set
if (name == null) {
throw new ApiException("Missing the required parameter 'name' when calling deleteCSINode(Async)");
}
return deleteCSINodeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
private ApiResponse deleteCSINodeWithHttpInfo(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCSINodeValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCSINodeAsync(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCSINodeValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCSINodeRequest {
private final String name;
private String pretty;
private String dryRun;
private Integer gracePeriodSeconds;
private Boolean orphanDependents;
private String propagationPolicy;
private V1DeleteOptions body;
private APIdeleteCSINodeRequest(String name) {
this.name = name;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCSINodeRequest
*/
public APIdeleteCSINodeRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCSINode
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCSINodeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
/**
* Execute deleteCSINode request
* @return V1CSINode
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public V1CSINode execute() throws ApiException {
ApiResponse localVarResp = deleteCSINodeWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
return localVarResp.getData();
}
/**
* Execute deleteCSINode request with HTTP info returned
* @return ApiResponse<V1CSINode>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCSINodeWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
}
/**
* Execute deleteCSINode request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return deleteCSINodeAsync(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
}
/**
*
* delete a CSINode
* @param name name of the CSINode (required)
* @return APIdeleteCSINodeRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public APIdeleteCSINodeRequest deleteCSINode(String name) {
return new APIdeleteCSINodeRequest(name);
}
private okhttp3.Call deleteCollectionCSIDriverCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csidrivers";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (_continue != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("continue", _continue));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldSelector", fieldSelector));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (labelSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("labelSelector", labelSelector));
}
if (limit != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
if (resourceVersion != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersion", resourceVersion));
}
if (resourceVersionMatch != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersionMatch", resourceVersionMatch));
}
if (sendInitialEvents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("sendInitialEvents", sendInitialEvents));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCollectionCSIDriverValidateBeforeCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
return deleteCollectionCSIDriverCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
private ApiResponse deleteCollectionCSIDriverWithHttpInfo(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionCSIDriverValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCollectionCSIDriverAsync(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionCSIDriverValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCollectionCSIDriverRequest {
private String pretty;
private String _continue;
private String dryRun;
private String fieldSelector;
private Integer gracePeriodSeconds;
private String labelSelector;
private Integer limit;
private Boolean orphanDependents;
private String propagationPolicy;
private String resourceVersion;
private String resourceVersionMatch;
private Boolean sendInitialEvents;
private Integer timeoutSeconds;
private V1DeleteOptions body;
private APIdeleteCollectionCSIDriverRequest() {
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set _continue
* @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest _continue(String _continue) {
this._continue = _continue;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldSelector
* @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest fieldSelector(String fieldSelector) {
this.fieldSelector = fieldSelector;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set labelSelector
* @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest labelSelector(String labelSelector) {
this.labelSelector = labelSelector;
return this;
}
/**
* Set limit
* @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest limit(Integer limit) {
this.limit = limit;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set resourceVersion
* @param resourceVersion resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest resourceVersion(String resourceVersion) {
this.resourceVersion = resourceVersion;
return this;
}
/**
* Set resourceVersionMatch
* @param resourceVersionMatch resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest resourceVersionMatch(String resourceVersionMatch) {
this.resourceVersionMatch = resourceVersionMatch;
return this;
}
/**
* Set sendInitialEvents
* @param sendInitialEvents `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest sendInitialEvents(Boolean sendInitialEvents) {
this.sendInitialEvents = sendInitialEvents;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCollectionCSIDriverRequest
*/
public APIdeleteCollectionCSIDriverRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCollectionCSIDriver
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCollectionCSIDriverCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
/**
* Execute deleteCollectionCSIDriver request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteCollectionCSIDriverWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
return localVarResp.getData();
}
/**
* Execute deleteCollectionCSIDriver request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCollectionCSIDriverWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
}
/**
* Execute deleteCollectionCSIDriver request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIdeleteCollectionCSIDriverRequest deleteCollectionCSIDriver() {
return new APIdeleteCollectionCSIDriverRequest();
}
private okhttp3.Call deleteCollectionCSINodeCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/csinodes";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (_continue != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("continue", _continue));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldSelector", fieldSelector));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (labelSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("labelSelector", labelSelector));
}
if (limit != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
if (resourceVersion != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersion", resourceVersion));
}
if (resourceVersionMatch != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersionMatch", resourceVersionMatch));
}
if (sendInitialEvents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("sendInitialEvents", sendInitialEvents));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCollectionCSINodeValidateBeforeCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
return deleteCollectionCSINodeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
private ApiResponse deleteCollectionCSINodeWithHttpInfo(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionCSINodeValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCollectionCSINodeAsync(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionCSINodeValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCollectionCSINodeRequest {
private String pretty;
private String _continue;
private String dryRun;
private String fieldSelector;
private Integer gracePeriodSeconds;
private String labelSelector;
private Integer limit;
private Boolean orphanDependents;
private String propagationPolicy;
private String resourceVersion;
private String resourceVersionMatch;
private Boolean sendInitialEvents;
private Integer timeoutSeconds;
private V1DeleteOptions body;
private APIdeleteCollectionCSINodeRequest() {
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set _continue
* @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest _continue(String _continue) {
this._continue = _continue;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldSelector
* @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest fieldSelector(String fieldSelector) {
this.fieldSelector = fieldSelector;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set labelSelector
* @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest labelSelector(String labelSelector) {
this.labelSelector = labelSelector;
return this;
}
/**
* Set limit
* @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest limit(Integer limit) {
this.limit = limit;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set resourceVersion
* @param resourceVersion resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest resourceVersion(String resourceVersion) {
this.resourceVersion = resourceVersion;
return this;
}
/**
* Set resourceVersionMatch
* @param resourceVersionMatch resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest resourceVersionMatch(String resourceVersionMatch) {
this.resourceVersionMatch = resourceVersionMatch;
return this;
}
/**
* Set sendInitialEvents
* @param sendInitialEvents `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest sendInitialEvents(Boolean sendInitialEvents) {
this.sendInitialEvents = sendInitialEvents;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCollectionCSINodeRequest
*/
public APIdeleteCollectionCSINodeRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCollectionCSINode
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCollectionCSINodeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
/**
* Execute deleteCollectionCSINode request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteCollectionCSINodeWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
return localVarResp.getData();
}
/**
* Execute deleteCollectionCSINode request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCollectionCSINodeWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
}
/**
* Execute deleteCollectionCSINode request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIdeleteCollectionCSINodeRequest deleteCollectionCSINode() {
return new APIdeleteCollectionCSINodeRequest();
}
private okhttp3.Call deleteCollectionNamespacedCSIStorageCapacityCall(String namespace, String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/namespaces/{namespace}/csistoragecapacities"
.replace("{" + "namespace" + "}", localVarApiClient.escapeString(namespace.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (_continue != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("continue", _continue));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldSelector", fieldSelector));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (labelSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("labelSelector", labelSelector));
}
if (limit != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
if (resourceVersion != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersion", resourceVersion));
}
if (resourceVersionMatch != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersionMatch", resourceVersionMatch));
}
if (sendInitialEvents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("sendInitialEvents", sendInitialEvents));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCollectionNamespacedCSIStorageCapacityValidateBeforeCall(String namespace, String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'namespace' is set
if (namespace == null) {
throw new ApiException("Missing the required parameter 'namespace' when calling deleteCollectionNamespacedCSIStorageCapacity(Async)");
}
return deleteCollectionNamespacedCSIStorageCapacityCall(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
private ApiResponse deleteCollectionNamespacedCSIStorageCapacityWithHttpInfo(String namespace, String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionNamespacedCSIStorageCapacityValidateBeforeCall(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCollectionNamespacedCSIStorageCapacityAsync(String namespace, String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionNamespacedCSIStorageCapacityValidateBeforeCall(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCollectionNamespacedCSIStorageCapacityRequest {
private final String namespace;
private String pretty;
private String _continue;
private String dryRun;
private String fieldSelector;
private Integer gracePeriodSeconds;
private String labelSelector;
private Integer limit;
private Boolean orphanDependents;
private String propagationPolicy;
private String resourceVersion;
private String resourceVersionMatch;
private Boolean sendInitialEvents;
private Integer timeoutSeconds;
private V1DeleteOptions body;
private APIdeleteCollectionNamespacedCSIStorageCapacityRequest(String namespace) {
this.namespace = namespace;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set _continue
* @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest _continue(String _continue) {
this._continue = _continue;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldSelector
* @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest fieldSelector(String fieldSelector) {
this.fieldSelector = fieldSelector;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set labelSelector
* @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest labelSelector(String labelSelector) {
this.labelSelector = labelSelector;
return this;
}
/**
* Set limit
* @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest limit(Integer limit) {
this.limit = limit;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set resourceVersion
* @param resourceVersion resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest resourceVersion(String resourceVersion) {
this.resourceVersion = resourceVersion;
return this;
}
/**
* Set resourceVersionMatch
* @param resourceVersionMatch resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest resourceVersionMatch(String resourceVersionMatch) {
this.resourceVersionMatch = resourceVersionMatch;
return this;
}
/**
* Set sendInitialEvents
* @param sendInitialEvents `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest sendInitialEvents(Boolean sendInitialEvents) {
this.sendInitialEvents = sendInitialEvents;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCollectionNamespacedCSIStorageCapacity
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCollectionNamespacedCSIStorageCapacityCall(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
/**
* Execute deleteCollectionNamespacedCSIStorageCapacity request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteCollectionNamespacedCSIStorageCapacityWithHttpInfo(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
return localVarResp.getData();
}
/**
* Execute deleteCollectionNamespacedCSIStorageCapacity request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCollectionNamespacedCSIStorageCapacityWithHttpInfo(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
}
/**
* Execute deleteCollectionNamespacedCSIStorageCapacity request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return deleteCollectionNamespacedCSIStorageCapacityAsync(namespace, pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
}
/**
*
* delete collection of CSIStorageCapacity
* @param namespace object name and auth scope, such as for teams and projects (required)
* @return APIdeleteCollectionNamespacedCSIStorageCapacityRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public APIdeleteCollectionNamespacedCSIStorageCapacityRequest deleteCollectionNamespacedCSIStorageCapacity(String namespace) {
return new APIdeleteCollectionNamespacedCSIStorageCapacityRequest(namespace);
}
private okhttp3.Call deleteCollectionStorageClassCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/storageclasses";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (_continue != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("continue", _continue));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldSelector", fieldSelector));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (labelSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("labelSelector", labelSelector));
}
if (limit != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
if (resourceVersion != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersion", resourceVersion));
}
if (resourceVersionMatch != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersionMatch", resourceVersionMatch));
}
if (sendInitialEvents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("sendInitialEvents", sendInitialEvents));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCollectionStorageClassValidateBeforeCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
return deleteCollectionStorageClassCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
private ApiResponse deleteCollectionStorageClassWithHttpInfo(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionStorageClassValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCollectionStorageClassAsync(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionStorageClassValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCollectionStorageClassRequest {
private String pretty;
private String _continue;
private String dryRun;
private String fieldSelector;
private Integer gracePeriodSeconds;
private String labelSelector;
private Integer limit;
private Boolean orphanDependents;
private String propagationPolicy;
private String resourceVersion;
private String resourceVersionMatch;
private Boolean sendInitialEvents;
private Integer timeoutSeconds;
private V1DeleteOptions body;
private APIdeleteCollectionStorageClassRequest() {
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set _continue
* @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest _continue(String _continue) {
this._continue = _continue;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldSelector
* @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest fieldSelector(String fieldSelector) {
this.fieldSelector = fieldSelector;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set labelSelector
* @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest labelSelector(String labelSelector) {
this.labelSelector = labelSelector;
return this;
}
/**
* Set limit
* @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest limit(Integer limit) {
this.limit = limit;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set resourceVersion
* @param resourceVersion resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest resourceVersion(String resourceVersion) {
this.resourceVersion = resourceVersion;
return this;
}
/**
* Set resourceVersionMatch
* @param resourceVersionMatch resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest resourceVersionMatch(String resourceVersionMatch) {
this.resourceVersionMatch = resourceVersionMatch;
return this;
}
/**
* Set sendInitialEvents
* @param sendInitialEvents `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest sendInitialEvents(Boolean sendInitialEvents) {
this.sendInitialEvents = sendInitialEvents;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCollectionStorageClassRequest
*/
public APIdeleteCollectionStorageClassRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCollectionStorageClass
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCollectionStorageClassCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
/**
* Execute deleteCollectionStorageClass request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteCollectionStorageClassWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
return localVarResp.getData();
}
/**
* Execute deleteCollectionStorageClass request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCollectionStorageClassWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
}
/**
* Execute deleteCollectionStorageClass request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIdeleteCollectionStorageClassRequest deleteCollectionStorageClass() {
return new APIdeleteCollectionStorageClassRequest();
}
private okhttp3.Call deleteCollectionVolumeAttachmentCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/volumeattachments";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (_continue != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("continue", _continue));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (fieldSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("fieldSelector", fieldSelector));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (labelSelector != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("labelSelector", labelSelector));
}
if (limit != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
if (resourceVersion != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersion", resourceVersion));
}
if (resourceVersionMatch != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("resourceVersionMatch", resourceVersionMatch));
}
if (sendInitialEvents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("sendInitialEvents", sendInitialEvents));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteCollectionVolumeAttachmentValidateBeforeCall(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
return deleteCollectionVolumeAttachmentCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
private ApiResponse deleteCollectionVolumeAttachmentWithHttpInfo(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionVolumeAttachmentValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteCollectionVolumeAttachmentAsync(String pretty, String _continue, String dryRun, String fieldSelector, Integer gracePeriodSeconds, String labelSelector, Integer limit, Boolean orphanDependents, String propagationPolicy, String resourceVersion, String resourceVersionMatch, Boolean sendInitialEvents, Integer timeoutSeconds, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteCollectionVolumeAttachmentValidateBeforeCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteCollectionVolumeAttachmentRequest {
private String pretty;
private String _continue;
private String dryRun;
private String fieldSelector;
private Integer gracePeriodSeconds;
private String labelSelector;
private Integer limit;
private Boolean orphanDependents;
private String propagationPolicy;
private String resourceVersion;
private String resourceVersionMatch;
private Boolean sendInitialEvents;
private Integer timeoutSeconds;
private V1DeleteOptions body;
private APIdeleteCollectionVolumeAttachmentRequest() {
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set _continue
* @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest _continue(String _continue) {
this._continue = _continue;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set fieldSelector
* @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest fieldSelector(String fieldSelector) {
this.fieldSelector = fieldSelector;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set labelSelector
* @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest labelSelector(String labelSelector) {
this.labelSelector = labelSelector;
return this;
}
/**
* Set limit
* @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest limit(Integer limit) {
this.limit = limit;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set resourceVersion
* @param resourceVersion resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest resourceVersion(String resourceVersion) {
this.resourceVersion = resourceVersion;
return this;
}
/**
* Set resourceVersionMatch
* @param resourceVersionMatch resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest resourceVersionMatch(String resourceVersionMatch) {
this.resourceVersionMatch = resourceVersionMatch;
return this;
}
/**
* Set sendInitialEvents
* @param sendInitialEvents `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest sendInitialEvents(Boolean sendInitialEvents) {
this.sendInitialEvents = sendInitialEvents;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteCollectionVolumeAttachmentRequest
*/
public APIdeleteCollectionVolumeAttachmentRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteCollectionVolumeAttachment
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteCollectionVolumeAttachmentCall(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body, _callback);
}
/**
* Execute deleteCollectionVolumeAttachment request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteCollectionVolumeAttachmentWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
return localVarResp.getData();
}
/**
* Execute deleteCollectionVolumeAttachment request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteCollectionVolumeAttachmentWithHttpInfo(pretty, _continue, dryRun, fieldSelector, gracePeriodSeconds, labelSelector, limit, orphanDependents, propagationPolicy, resourceVersion, resourceVersionMatch, sendInitialEvents, timeoutSeconds, body);
}
/**
* Execute deleteCollectionVolumeAttachment request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
*/
public APIdeleteCollectionVolumeAttachmentRequest deleteCollectionVolumeAttachment() {
return new APIdeleteCollectionVolumeAttachmentRequest();
}
private okhttp3.Call deleteNamespacedCSIStorageCapacityCall(String name, String namespace, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/namespaces/{namespace}/csistoragecapacities/{name}"
.replace("{" + "name" + "}", localVarApiClient.escapeString(name.toString()))
.replace("{" + "namespace" + "}", localVarApiClient.escapeString(namespace.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteNamespacedCSIStorageCapacityValidateBeforeCall(String name, String namespace, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'name' is set
if (name == null) {
throw new ApiException("Missing the required parameter 'name' when calling deleteNamespacedCSIStorageCapacity(Async)");
}
// verify the required parameter 'namespace' is set
if (namespace == null) {
throw new ApiException("Missing the required parameter 'namespace' when calling deleteNamespacedCSIStorageCapacity(Async)");
}
return deleteNamespacedCSIStorageCapacityCall(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
private ApiResponse deleteNamespacedCSIStorageCapacityWithHttpInfo(String name, String namespace, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteNamespacedCSIStorageCapacityValidateBeforeCall(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteNamespacedCSIStorageCapacityAsync(String name, String namespace, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteNamespacedCSIStorageCapacityValidateBeforeCall(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteNamespacedCSIStorageCapacityRequest {
private final String name;
private final String namespace;
private String pretty;
private String dryRun;
private Integer gracePeriodSeconds;
private Boolean orphanDependents;
private String propagationPolicy;
private V1DeleteOptions body;
private APIdeleteNamespacedCSIStorageCapacityRequest(String name, String namespace) {
this.name = name;
this.namespace = namespace;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
*/
public APIdeleteNamespacedCSIStorageCapacityRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteNamespacedCSIStorageCapacity
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteNamespacedCSIStorageCapacityCall(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
/**
* Execute deleteNamespacedCSIStorageCapacity request
* @return V1Status
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public V1Status execute() throws ApiException {
ApiResponse localVarResp = deleteNamespacedCSIStorageCapacityWithHttpInfo(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
return localVarResp.getData();
}
/**
* Execute deleteNamespacedCSIStorageCapacity request with HTTP info returned
* @return ApiResponse<V1Status>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteNamespacedCSIStorageCapacityWithHttpInfo(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
}
/**
* Execute deleteNamespacedCSIStorageCapacity request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return deleteNamespacedCSIStorageCapacityAsync(name, namespace, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
}
/**
*
* delete a CSIStorageCapacity
* @param name name of the CSIStorageCapacity (required)
* @param namespace object name and auth scope, such as for teams and projects (required)
* @return APIdeleteNamespacedCSIStorageCapacityRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public APIdeleteNamespacedCSIStorageCapacityRequest deleteNamespacedCSIStorageCapacity(String name, String namespace) {
return new APIdeleteNamespacedCSIStorageCapacityRequest(name, namespace);
}
private okhttp3.Call deleteStorageClassCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/storageclasses/{name}"
.replace("{" + "name" + "}", localVarApiClient.escapeString(name.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteStorageClassValidateBeforeCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'name' is set
if (name == null) {
throw new ApiException("Missing the required parameter 'name' when calling deleteStorageClass(Async)");
}
return deleteStorageClassCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
private ApiResponse deleteStorageClassWithHttpInfo(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteStorageClassValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteStorageClassAsync(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteStorageClassValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIdeleteStorageClassRequest {
private final String name;
private String pretty;
private String dryRun;
private Integer gracePeriodSeconds;
private Boolean orphanDependents;
private String propagationPolicy;
private V1DeleteOptions body;
private APIdeleteStorageClassRequest(String name) {
this.name = name;
}
/**
* Set pretty
* @param pretty If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest pretty(String pretty) {
this.pretty = pretty;
return this;
}
/**
* Set dryRun
* @param dryRun When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest dryRun(String dryRun) {
this.dryRun = dryRun;
return this;
}
/**
* Set gracePeriodSeconds
* @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest gracePeriodSeconds(Integer gracePeriodSeconds) {
this.gracePeriodSeconds = gracePeriodSeconds;
return this;
}
/**
* Set orphanDependents
* @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest orphanDependents(Boolean orphanDependents) {
this.orphanDependents = orphanDependents;
return this;
}
/**
* Set propagationPolicy
* @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest propagationPolicy(String propagationPolicy) {
this.propagationPolicy = propagationPolicy;
return this;
}
/**
* Set body
* @param body (optional)
* @return APIdeleteStorageClassRequest
*/
public APIdeleteStorageClassRequest body(V1DeleteOptions body) {
this.body = body;
return this;
}
/**
* Build call for deleteStorageClass
* @param _callback ApiCallback API callback
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return deleteStorageClassCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
/**
* Execute deleteStorageClass request
* @return V1StorageClass
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public V1StorageClass execute() throws ApiException {
ApiResponse localVarResp = deleteStorageClassWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
return localVarResp.getData();
}
/**
* Execute deleteStorageClass request with HTTP info returned
* @return ApiResponse<V1StorageClass>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return deleteStorageClassWithHttpInfo(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body);
}
/**
* Execute deleteStorageClass request (asynchronously)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return deleteStorageClassAsync(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
}
/**
*
* delete a StorageClass
* @param name name of the StorageClass (required)
* @return APIdeleteStorageClassRequest
* @http.response.details
Status Code
Description
Response Headers
200
OK
-
202
Accepted
-
401
Unauthorized
-
*/
public APIdeleteStorageClassRequest deleteStorageClass(String name) {
return new APIdeleteStorageClassRequest(name);
}
private okhttp3.Call deleteVolumeAttachmentCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/apis/storage.k8s.io/v1/volumeattachments/{name}"
.replace("{" + "name" + "}", localVarApiClient.escapeString(name.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (pretty != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("pretty", pretty));
}
if (dryRun != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("dryRun", dryRun));
}
if (gracePeriodSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("gracePeriodSeconds", gracePeriodSeconds));
}
if (orphanDependents != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("orphanDependents", orphanDependents));
}
if (propagationPolicy != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("propagationPolicy", propagationPolicy));
}
final String[] localVarAccepts = {
"application/json",
"application/yaml",
"application/vnd.kubernetes.protobuf"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "BearerToken" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteVolumeAttachmentValidateBeforeCall(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'name' is set
if (name == null) {
throw new ApiException("Missing the required parameter 'name' when calling deleteVolumeAttachment(Async)");
}
return deleteVolumeAttachmentCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
}
private ApiResponse deleteVolumeAttachmentWithHttpInfo(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body) throws ApiException {
okhttp3.Call localVarCall = deleteVolumeAttachmentValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call deleteVolumeAttachmentAsync(String name, String pretty, String dryRun, Integer gracePeriodSeconds, Boolean orphanDependents, String propagationPolicy, V1DeleteOptions body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteVolumeAttachmentValidateBeforeCall(name, pretty, dryRun, gracePeriodSeconds, orphanDependents, propagationPolicy, body, _callback);
Type localVarReturnType = new TypeToken