|
42 | 42 | import com.aspose.cloud.cells.model.AutoFilterResponse;
|
43 | 43 | import com.aspose.cloud.cells.model.AutoFitterOptions;
|
44 | 44 | import com.aspose.cloud.cells.model.AutoShapesResponse;
|
| 45 | +import com.aspose.cloud.cells.model.BatchConvertRequest; |
45 | 46 | import com.aspose.cloud.cells.model.CalculationOptions;
|
46 | 47 | import com.aspose.cloud.cells.model.CellResponse;
|
47 | 48 | import com.aspose.cloud.cells.model.CellsCloudResponse;
|
|
82 | 83 | import com.aspose.cloud.cells.model.LineResponse;
|
83 | 84 | import com.aspose.cloud.cells.model.ListObject;
|
84 | 85 | import com.aspose.cloud.cells.model.ListObjectsResponse;
|
| 86 | +import com.aspose.cloud.cells.model.MatchConditionRequest; |
85 | 87 | import com.aspose.cloud.cells.model.MergedCellResponse;
|
86 | 88 | import com.aspose.cloud.cells.model.MergedCellsResponse;
|
87 | 89 | import com.aspose.cloud.cells.model.NameResponse;
|
@@ -35946,6 +35948,153 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don
|
35946 | 35948 | apiClient.executeAsync(call, localVarReturnType, callback);
|
35947 | 35949 | return call;
|
35948 | 35950 | }
|
| 35951 | + /** |
| 35952 | + * Build call for cellsWorksheetsDeleteWorksheets |
| 35953 | + * @param name (required) |
| 35954 | + * @param matchCondition (required) |
| 35955 | + * @param folder (optional) |
| 35956 | + * @param storageName (optional) |
| 35957 | + * @param progressListener Progress listener |
| 35958 | + * @param progressRequestListener Progress request listener |
| 35959 | + * @return Call to execute |
| 35960 | + * @throws ApiException If fail to serialize the request body object |
| 35961 | + */ |
| 35962 | + public com.squareup.okhttp.Call cellsWorksheetsDeleteWorksheetsCall(String name, MatchConditionRequest matchCondition, String folder, String storageName, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 35963 | + Object localVarPostBody = matchCondition; |
| 35964 | + |
| 35965 | + // create path and map variables |
| 35966 | + String localVarPath = "/cells/{name}/worksheets" |
| 35967 | + .replaceAll("\\{" + "name" + "\\}", apiClient.escapeString(name.toString())); |
| 35968 | + |
| 35969 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 35970 | + if (folder != null) |
| 35971 | + localVarQueryParams.addAll(apiClient.parameterToPairs("", "folder", folder)); |
| 35972 | + if (storageName != null) |
| 35973 | + localVarQueryParams.addAll(apiClient.parameterToPairs("", "storageName", storageName)); |
| 35974 | + |
| 35975 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 35976 | + |
| 35977 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 35978 | + |
| 35979 | + final String[] localVarAccepts = { |
| 35980 | + "application/json" |
| 35981 | + }; |
| 35982 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 35983 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 35984 | + |
| 35985 | + final String[] localVarContentTypes = { |
| 35986 | + "application/json" |
| 35987 | + }; |
| 35988 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 35989 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 35990 | + |
| 35991 | + if(progressListener != null) { |
| 35992 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 35993 | + @Override |
| 35994 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 35995 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 35996 | + return originalResponse.newBuilder() |
| 35997 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 35998 | + .build(); |
| 35999 | + } |
| 36000 | + }); |
| 36001 | + } |
| 36002 | + |
| 36003 | + String[] localVarAuthNames = new String[] { }; |
| 36004 | + return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 36005 | + } |
| 36006 | + |
| 36007 | + @SuppressWarnings("rawtypes") |
| 36008 | + private com.squareup.okhttp.Call cellsWorksheetsDeleteWorksheetsValidateBeforeCall(String name, MatchConditionRequest matchCondition, String folder, String storageName, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 36009 | + |
| 36010 | + // verify the required parameter 'name' is set |
| 36011 | + if (name == null) { |
| 36012 | + throw new ApiException("Missing the required parameter 'name' when calling cellsWorksheetsDeleteWorksheets(Async)"); |
| 36013 | + } |
| 36014 | + |
| 36015 | + // verify the required parameter 'matchCondition' is set |
| 36016 | + if (matchCondition == null) { |
| 36017 | + throw new ApiException("Missing the required parameter 'matchCondition' when calling cellsWorksheetsDeleteWorksheets(Async)"); |
| 36018 | + } |
| 36019 | + |
| 36020 | + |
| 36021 | + com.squareup.okhttp.Call call = cellsWorksheetsDeleteWorksheetsCall(name, matchCondition, folder, storageName, progressListener, progressRequestListener); |
| 36022 | + return call; |
| 36023 | + |
| 36024 | + |
| 36025 | + |
| 36026 | + |
| 36027 | + |
| 36028 | + } |
| 36029 | + |
| 36030 | + /** |
| 36031 | + * Read worksheets info. |
| 36032 | + * |
| 36033 | + * @param name (required) |
| 36034 | + * @param matchCondition (required) |
| 36035 | + * @param folder (optional) |
| 36036 | + * @param storageName (optional) |
| 36037 | + * @return CellsCloudResponse |
| 36038 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 36039 | + */ |
| 36040 | + public CellsCloudResponse cellsWorksheetsDeleteWorksheets(String name, MatchConditionRequest matchCondition, String folder, String storageName) throws ApiException { |
| 36041 | + ApiResponse<CellsCloudResponse> resp = cellsWorksheetsDeleteWorksheetsWithHttpInfo(name, matchCondition, folder, storageName); |
| 36042 | + return resp.getData(); |
| 36043 | + } |
| 36044 | + |
| 36045 | + /** |
| 36046 | + * Read worksheets info. |
| 36047 | + * |
| 36048 | + * @param name (required) |
| 36049 | + * @param matchCondition (required) |
| 36050 | + * @param folder (optional) |
| 36051 | + * @param storageName (optional) |
| 36052 | + * @return ApiResponse<CellsCloudResponse> |
| 36053 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 36054 | + */ |
| 36055 | + public ApiResponse<CellsCloudResponse> cellsWorksheetsDeleteWorksheetsWithHttpInfo(String name, MatchConditionRequest matchCondition, String folder, String storageName) throws ApiException { |
| 36056 | + com.squareup.okhttp.Call call = cellsWorksheetsDeleteWorksheetsValidateBeforeCall(name, matchCondition, folder, storageName, null, null); |
| 36057 | + Type localVarReturnType = new TypeToken<CellsCloudResponse>(){}.getType(); |
| 36058 | + return apiClient.execute(call, localVarReturnType); |
| 36059 | + } |
| 36060 | + |
| 36061 | + /** |
| 36062 | + * Read worksheets info. (asynchronously) |
| 36063 | + * |
| 36064 | + * @param name (required) |
| 36065 | + * @param matchCondition (required) |
| 36066 | + * @param folder (optional) |
| 36067 | + * @param storageName (optional) |
| 36068 | + * @param callback The callback to be executed when the API call finishes |
| 36069 | + * @return The request call |
| 36070 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 36071 | + */ |
| 36072 | + public com.squareup.okhttp.Call cellsWorksheetsDeleteWorksheetsAsync(String name, MatchConditionRequest matchCondition, String folder, String storageName, final ApiCallback<CellsCloudResponse> callback) throws ApiException { |
| 36073 | + |
| 36074 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 36075 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 36076 | + |
| 36077 | + if (callback != null) { |
| 36078 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 36079 | + @Override |
| 36080 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 36081 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 36082 | + } |
| 36083 | + }; |
| 36084 | + |
| 36085 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 36086 | + @Override |
| 36087 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 36088 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 36089 | + } |
| 36090 | + }; |
| 36091 | + } |
| 36092 | + |
| 36093 | + com.squareup.okhttp.Call call = cellsWorksheetsDeleteWorksheetsValidateBeforeCall(name, matchCondition, folder, storageName, progressListener, progressRequestListener); |
| 36094 | + Type localVarReturnType = new TypeToken<CellsCloudResponse>(){}.getType(); |
| 36095 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 36096 | + return call; |
| 36097 | + } |
35949 | 36098 | /**
|
35950 | 36099 | * Build call for cellsWorksheetsGetNamedRanges
|
35951 | 36100 | * @param name Document name. (required)
|
@@ -42092,6 +42241,131 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don
|
42092 | 42241 | apiClient.executeAsync(call, localVarReturnType, callback);
|
42093 | 42242 | return call;
|
42094 | 42243 | }
|
| 42244 | + /** |
| 42245 | + * Build call for postBatchConvert |
| 42246 | + * @param batchConvertRequest (required) |
| 42247 | + * @param progressListener Progress listener |
| 42248 | + * @param progressRequestListener Progress request listener |
| 42249 | + * @return Call to execute |
| 42250 | + * @throws ApiException If fail to serialize the request body object |
| 42251 | + */ |
| 42252 | + public com.squareup.okhttp.Call postBatchConvertCall(BatchConvertRequest batchConvertRequest, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 42253 | + Object localVarPostBody = batchConvertRequest; |
| 42254 | + |
| 42255 | + // create path and map variables |
| 42256 | + String localVarPath = "/cells/batch/convert"; |
| 42257 | + |
| 42258 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 42259 | + |
| 42260 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 42261 | + |
| 42262 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 42263 | + |
| 42264 | + final String[] localVarAccepts = { |
| 42265 | + "application/json" |
| 42266 | + }; |
| 42267 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 42268 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 42269 | + |
| 42270 | + final String[] localVarContentTypes = { |
| 42271 | + "application/json" |
| 42272 | + }; |
| 42273 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 42274 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 42275 | + |
| 42276 | + if(progressListener != null) { |
| 42277 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 42278 | + @Override |
| 42279 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 42280 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 42281 | + return originalResponse.newBuilder() |
| 42282 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 42283 | + .build(); |
| 42284 | + } |
| 42285 | + }); |
| 42286 | + } |
| 42287 | + |
| 42288 | + String[] localVarAuthNames = new String[] { }; |
| 42289 | + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 42290 | + } |
| 42291 | + |
| 42292 | + @SuppressWarnings("rawtypes") |
| 42293 | + private com.squareup.okhttp.Call postBatchConvertValidateBeforeCall(BatchConvertRequest batchConvertRequest, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 42294 | + |
| 42295 | + // verify the required parameter 'batchConvertRequest' is set |
| 42296 | + if (batchConvertRequest == null) { |
| 42297 | + throw new ApiException("Missing the required parameter 'batchConvertRequest' when calling postBatchConvert(Async)"); |
| 42298 | + } |
| 42299 | + |
| 42300 | + |
| 42301 | + com.squareup.okhttp.Call call = postBatchConvertCall(batchConvertRequest, progressListener, progressRequestListener); |
| 42302 | + return call; |
| 42303 | + |
| 42304 | + |
| 42305 | + |
| 42306 | + |
| 42307 | + |
| 42308 | + } |
| 42309 | + |
| 42310 | + /** |
| 42311 | + * |
| 42312 | + * |
| 42313 | + * @param batchConvertRequest (required) |
| 42314 | + * @return File |
| 42315 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 42316 | + */ |
| 42317 | + public File postBatchConvert(BatchConvertRequest batchConvertRequest) throws ApiException { |
| 42318 | + ApiResponse<File> resp = postBatchConvertWithHttpInfo(batchConvertRequest); |
| 42319 | + return resp.getData(); |
| 42320 | + } |
| 42321 | + |
| 42322 | + /** |
| 42323 | + * |
| 42324 | + * |
| 42325 | + * @param batchConvertRequest (required) |
| 42326 | + * @return ApiResponse<File> |
| 42327 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 42328 | + */ |
| 42329 | + public ApiResponse<File> postBatchConvertWithHttpInfo(BatchConvertRequest batchConvertRequest) throws ApiException { |
| 42330 | + com.squareup.okhttp.Call call = postBatchConvertValidateBeforeCall(batchConvertRequest, null, null); |
| 42331 | + Type localVarReturnType = new TypeToken<File>(){}.getType(); |
| 42332 | + return apiClient.execute(call, localVarReturnType); |
| 42333 | + } |
| 42334 | + |
| 42335 | + /** |
| 42336 | + * (asynchronously) |
| 42337 | + * |
| 42338 | + * @param batchConvertRequest (required) |
| 42339 | + * @param callback The callback to be executed when the API call finishes |
| 42340 | + * @return The request call |
| 42341 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 42342 | + */ |
| 42343 | + public com.squareup.okhttp.Call postBatchConvertAsync(BatchConvertRequest batchConvertRequest, final ApiCallback<File> callback) throws ApiException { |
| 42344 | + |
| 42345 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 42346 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 42347 | + |
| 42348 | + if (callback != null) { |
| 42349 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 42350 | + @Override |
| 42351 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 42352 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 42353 | + } |
| 42354 | + }; |
| 42355 | + |
| 42356 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 42357 | + @Override |
| 42358 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 42359 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 42360 | + } |
| 42361 | + }; |
| 42362 | + } |
| 42363 | + |
| 42364 | + com.squareup.okhttp.Call call = postBatchConvertValidateBeforeCall(batchConvertRequest, progressListener, progressRequestListener); |
| 42365 | + Type localVarReturnType = new TypeToken<File>(){}.getType(); |
| 42366 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 42367 | + return call; |
| 42368 | + } |
42095 | 42369 | /**
|
42096 | 42370 | * Build call for storageExists
|
42097 | 42371 | * @param storageName Storage name (required)
|
|
0 commit comments