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.
/*
* FINBOURNE Luminesce Web API
*
* Contact: [email protected]
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package com.finbourne.luminesce.api;
import com.finbourne.luminesce.ApiCallback;
import com.finbourne.luminesce.ApiClient;
import com.finbourne.luminesce.ApiException;
import com.finbourne.luminesce.ApiResponse;
import com.finbourne.luminesce.Configuration;
import com.finbourne.luminesce.Pair;
import com.finbourne.luminesce.ProgressRequestBody;
import com.finbourne.luminesce.ProgressResponseBody;
import com.finbourne.luminesce.extensions.ConfigurationOptions;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import com.finbourne.luminesce.model.BackgroundMultiQueryProgressResponse;
import com.finbourne.luminesce.model.BackgroundMultiQueryResponse;
import com.finbourne.luminesce.model.BackgroundQueryCancelResponse;
import com.finbourne.luminesce.model.LusidProblemDetails;
import com.finbourne.luminesce.model.MultiQueryDefinitionType;
import java.time.OffsetDateTime;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class MultiQueryExecutionApi {
private ApiClient localVarApiClient;
private int localHostIndex;
private String localCustomBaseUrl;
public MultiQueryExecutionApi() {
this(Configuration.getDefaultApiClient());
}
public MultiQueryExecutionApi(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 cancelMultiQueryCall(String executionId, final ApiCallback _callback) throws ApiException {
return cancelMultiQueryCall(executionId, _callback, new ConfigurationOptions());
}
private okhttp3.Call cancelMultiQueryCall(String executionId, final ApiCallback _callback, ConfigurationOptions opts) 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 = null;
// create path and map variables
String localVarPath = "/api/MultiQueryBackground/{executionId}"
.replace("{" + "executionId" + "}", localVarApiClient.escapeString(executionId.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"text/plain",
"application/json",
"text/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "oauth2" };
return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, opts);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call cancelMultiQueryValidateBeforeCall(String executionId, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'executionId' is set
if (executionId == null) {
throw new ApiException("Missing the required parameter 'executionId' when calling cancelMultiQuery(Async)");
}
return cancelMultiQueryCall(executionId, _callback, opts);
}
private ApiResponse cancelMultiQueryWithHttpInfo(String executionId) throws ApiException {
okhttp3.Call localVarCall = cancelMultiQueryValidateBeforeCall(executionId, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse cancelMultiQueryWithHttpInfo(String executionId, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = cancelMultiQueryValidateBeforeCall(executionId, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call cancelMultiQueryAsync(String executionId, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = cancelMultiQueryValidateBeforeCall(executionId, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call cancelMultiQueryAsync(String executionId, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = cancelMultiQueryValidateBeforeCall(executionId, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIcancelMultiQueryRequest {
private final String executionId;
private APIcancelMultiQueryRequest(String executionId) {
this.executionId = executionId;
}
/**
* Build call for cancelMultiQuery
* @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
Success
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return cancelMultiQueryCall(executionId, _callback);
}
/**
* Execute cancelMultiQuery request
* @return BackgroundQueryCancelResponse
* @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
Success
-
*/
public BackgroundQueryCancelResponse execute() throws ApiException {
ApiResponse localVarResp = cancelMultiQueryWithHttpInfo(executionId);
return localVarResp.getData();
}
/**
* Execute cancelMultiQuery request. Use any specified configuration options to override any other configuration for this request only.
* @return BackgroundQueryCancelResponse
* @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
Success
-
*/
public BackgroundQueryCancelResponse execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = cancelMultiQueryWithHttpInfo(executionId, opts);
return localVarResp.getData();
}
/**
* Execute cancelMultiQuery request with HTTP info returned
* @return ApiResponse<BackgroundQueryCancelResponse>
* @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
Success
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return cancelMultiQueryWithHttpInfo(executionId);
}
/**
* Execute cancelMultiQuery request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<BackgroundQueryCancelResponse>
* @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
Success
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return cancelMultiQueryWithHttpInfo(executionId, opts);
}
/**
* Execute cancelMultiQuery 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
Success
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return cancelMultiQueryAsync(executionId, _callback);
}
/**
* Execute cancelMultiQuery request (asynchronously). Use any specified configuration options to override any other configuration for this request only.
* @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
Success
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return cancelMultiQueryAsync(executionId, _callback, opts);
}
}
/**
* CancelMultiQuery: Cancels / Clears a previously started query-set
* Cancel the query-set (if still running) / clear the data (if already returned) The following error codes are to be anticipated with standard Problem Detail reports: - 401 Unauthorized - 403 Forbidden - 404 Not Found : The requested query result doesn't exist and is not running.
* @param executionId ExecutionId returned when starting the query (required)
* @return APIcancelMultiQueryRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
*/
public APIcancelMultiQueryRequest cancelMultiQuery(String executionId) {
return new APIcancelMultiQueryRequest(executionId);
}
private okhttp3.Call getProgressOfMultiQueryCall(String executionId, final ApiCallback _callback) throws ApiException {
return getProgressOfMultiQueryCall(executionId, _callback, new ConfigurationOptions());
}
private okhttp3.Call getProgressOfMultiQueryCall(String executionId, final ApiCallback _callback, ConfigurationOptions opts) 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 = null;
// create path and map variables
String localVarPath = "/api/MultiQueryBackground/{executionId}"
.replace("{" + "executionId" + "}", localVarApiClient.escapeString(executionId.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"text/plain",
"application/json",
"text/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "oauth2" };
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, opts);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getProgressOfMultiQueryValidateBeforeCall(String executionId, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'executionId' is set
if (executionId == null) {
throw new ApiException("Missing the required parameter 'executionId' when calling getProgressOfMultiQuery(Async)");
}
return getProgressOfMultiQueryCall(executionId, _callback, opts);
}
private ApiResponse getProgressOfMultiQueryWithHttpInfo(String executionId) throws ApiException {
okhttp3.Call localVarCall = getProgressOfMultiQueryValidateBeforeCall(executionId, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getProgressOfMultiQueryWithHttpInfo(String executionId, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getProgressOfMultiQueryValidateBeforeCall(executionId, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getProgressOfMultiQueryAsync(String executionId, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getProgressOfMultiQueryValidateBeforeCall(executionId, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getProgressOfMultiQueryAsync(String executionId, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getProgressOfMultiQueryValidateBeforeCall(executionId, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetProgressOfMultiQueryRequest {
private final String executionId;
private APIgetProgressOfMultiQueryRequest(String executionId) {
this.executionId = executionId;
}
/**
* Build call for getProgressOfMultiQuery
* @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
Success
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getProgressOfMultiQueryCall(executionId, _callback);
}
/**
* Execute getProgressOfMultiQuery request
* @return BackgroundMultiQueryProgressResponse
* @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
Success
-
*/
public BackgroundMultiQueryProgressResponse execute() throws ApiException {
ApiResponse localVarResp = getProgressOfMultiQueryWithHttpInfo(executionId);
return localVarResp.getData();
}
/**
* Execute getProgressOfMultiQuery request. Use any specified configuration options to override any other configuration for this request only.
* @return BackgroundMultiQueryProgressResponse
* @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
Success
-
*/
public BackgroundMultiQueryProgressResponse execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getProgressOfMultiQueryWithHttpInfo(executionId, opts);
return localVarResp.getData();
}
/**
* Execute getProgressOfMultiQuery request with HTTP info returned
* @return ApiResponse<BackgroundMultiQueryProgressResponse>
* @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
Success
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getProgressOfMultiQueryWithHttpInfo(executionId);
}
/**
* Execute getProgressOfMultiQuery request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<BackgroundMultiQueryProgressResponse>
* @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
Success
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getProgressOfMultiQueryWithHttpInfo(executionId, opts);
}
/**
* Execute getProgressOfMultiQuery 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
Success
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getProgressOfMultiQueryAsync(executionId, _callback);
}
/**
* Execute getProgressOfMultiQuery request (asynchronously). Use any specified configuration options to override any other configuration for this request only.
* @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
Success
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getProgressOfMultiQueryAsync(executionId, _callback, opts);
}
}
/**
* GetProgressOfMultiQuery: View progress information for the entire query-set
* View progress information (up until this point) for the entire query-set The following error codes are to be anticipated with standard Problem Detail reports: - 401 Unauthorized - 403 Forbidden - 404 Not Found : The requested query result doesn't exist and is not running. - 429 Too Many Requests : Please try your request again soon 1. The query has been executed successfully in the past yet the server-instance receiving this request (e.g. from a load balancer) doesn't yet have this data available. 1. By virtue of the request you have just placed this will have started to load from the persisted cache and will soon be available. 1. It is also the case that the original server-instance to process the original query is likely to already be able to service this request.
* @param executionId ExecutionId returned when starting the query (required)
* @return APIgetProgressOfMultiQueryRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
*/
public APIgetProgressOfMultiQueryRequest getProgressOfMultiQuery(String executionId) {
return new APIgetProgressOfMultiQueryRequest(executionId);
}
private okhttp3.Call startQueriesCall(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, final ApiCallback _callback) throws ApiException {
return startQueriesCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback, new ConfigurationOptions());
}
private okhttp3.Call startQueriesCall(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, final ApiCallback _callback, ConfigurationOptions opts) 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 = "/api/MultiQueryBackground";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (type != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type));
}
if (asAt != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("asAt", asAt));
}
if (effectiveAt != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("effectiveAt", effectiveAt));
}
if (limit1 != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit1", limit1));
}
if (limit2 != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit2", limit2));
}
if (input1 != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("input1", input1));
}
if (input2 != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("input2", input2));
}
if (input3 != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("input3", input3));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
if (keepForSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("keepForSeconds", keepForSeconds));
}
final String[] localVarAccepts = {
"text/plain",
"application/json",
"text/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"text/plain"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { "oauth2" };
return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, opts);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call startQueriesValidateBeforeCall(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'type' is set
if (type == null) {
throw new ApiException("Missing the required parameter 'type' when calling startQueries(Async)");
}
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling startQueries(Async)");
}
return startQueriesCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback, opts);
}
private ApiResponse startQueriesWithHttpInfo(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds) throws ApiException {
okhttp3.Call localVarCall = startQueriesValidateBeforeCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse startQueriesWithHttpInfo(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = startQueriesValidateBeforeCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call startQueriesAsync(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = startQueriesValidateBeforeCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call startQueriesAsync(MultiQueryDefinitionType type, String body, OffsetDateTime asAt, OffsetDateTime effectiveAt, Integer limit1, Integer limit2, String input1, String input2, String input3, Integer timeoutSeconds, Integer keepForSeconds, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = startQueriesValidateBeforeCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIstartQueriesRequest {
private final MultiQueryDefinitionType type;
private final String body;
private OffsetDateTime asAt;
private OffsetDateTime effectiveAt;
private Integer limit1;
private Integer limit2;
private String input1;
private String input2;
private String input3;
private Integer timeoutSeconds;
private Integer keepForSeconds;
private APIstartQueriesRequest(MultiQueryDefinitionType type, String body) {
this.type = type;
this.body = body;
}
/**
* Set asAt
* @param asAt The AsAt time used by any bitemporal provider in the queries. (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest asAt(OffsetDateTime asAt) {
this.asAt = asAt;
return this;
}
/**
* Set effectiveAt
* @param effectiveAt The EffectiveAt time used by any bitemporal provider in the queries. (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest effectiveAt(OffsetDateTime effectiveAt) {
this.effectiveAt = effectiveAt;
return this;
}
/**
* Set limit1
* @param limit1 A limit that is applied to first-level queries (e.g. Instruments themselves) (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest limit1(Integer limit1) {
this.limit1 = limit1;
return this;
}
/**
* Set limit2
* @param limit2 A limit that is applied to second-level queries (e.g. Holdings based on the set of Instruments found) (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest limit2(Integer limit2) {
this.limit2 = limit2;
return this;
}
/**
* Set input1
* @param input1 A value available to queries, these vary by 'type' and are only used by some types at all. e.g. a start-date of some sort (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest input1(String input1) {
this.input1 = input1;
return this;
}
/**
* Set input2
* @param input2 A second value available to queries, these vary by 'type' and are only used by some types at all. (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest input2(String input2) {
this.input2 = input2;
return this;
}
/**
* Set input3
* @param input3 A third value available to queries, these vary by 'type' and are only used by some types at all. (optional)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest input3(String input3) {
this.input3 = input3;
return this;
}
/**
* Set timeoutSeconds
* @param timeoutSeconds Maximum time the query may run for, in seconds: <0 → ∞, 0 → 1200s (20m) (optional, default to 0)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest timeoutSeconds(Integer timeoutSeconds) {
this.timeoutSeconds = timeoutSeconds;
return this;
}
/**
* Set keepForSeconds
* @param keepForSeconds Maximum time the result may be kept for, in seconds: <0 → 1200 (20m), 0 → 28800 (8h), max = 2,678,400 (31d) (optional, default to 0)
* @return APIstartQueriesRequest
*/
public APIstartQueriesRequest keepForSeconds(Integer keepForSeconds) {
this.keepForSeconds = keepForSeconds;
return this;
}
/**
* Build call for startQueries
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return startQueriesCall(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback);
}
/**
* Execute startQueries request
* @return BackgroundMultiQueryResponse
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public BackgroundMultiQueryResponse execute() throws ApiException {
ApiResponse localVarResp = startQueriesWithHttpInfo(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds);
return localVarResp.getData();
}
/**
* Execute startQueries request. Use any specified configuration options to override any other configuration for this request only.
* @return BackgroundMultiQueryResponse
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public BackgroundMultiQueryResponse execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = startQueriesWithHttpInfo(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, opts);
return localVarResp.getData();
}
/**
* Execute startQueries request with HTTP info returned
* @return ApiResponse<BackgroundMultiQueryResponse>
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return startQueriesWithHttpInfo(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds);
}
/**
* Execute startQueries request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<BackgroundMultiQueryResponse>
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return startQueriesWithHttpInfo(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, opts);
}
/**
* Execute startQueries 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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return startQueriesAsync(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback);
}
/**
* Execute startQueries request (asynchronously). Use any specified configuration options to override any other configuration for this request only.
* @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
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return startQueriesAsync(type, body, asAt, effectiveAt, limit1, limit2, input1, input2, input3, timeoutSeconds, keepForSeconds, _callback, opts);
}
}
/**
* StartQueries: Runs a given set of Sql queries in the background
* Allow for starting a potentially long running query and getting back an immediate response with how to - fetch the data in various formats (if available, or if not simply being informed it is not yet ready), on a per result basis - view progress information (up until this point), for all results in one go - cancel the queries (if still running) / clear the data (if already returned) The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - there was something wrong with your query syntax (the issue was detected at parse-time) - 401 Unauthorized - 403 Forbidden
* @param type An enum value defining the set of statements being executed (required)
* @param body A \"search\" value (e.g. 'Apple' on an instrument search, a `Finbourne.Filtering` expression of Insights, etc.) In the cases where \"Nothing\" is valid for a `Finbourne.Filtering` expression, pass `True`. (required)
* @return APIstartQueriesRequest
* @http.response.details
Status Code
Description
Response Headers
202
Accepted
-
400
Bad Request
-
403
Forbidden
-
*/
public APIstartQueriesRequest startQueries(MultiQueryDefinitionType type, String body) {
return new APIstartQueriesRequest(type, body);
}
}