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 java.io.File;
import com.finbourne.luminesce.model.LusidProblemDetails;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class SqlExecutionApi {
private ApiClient localVarApiClient;
private int localHostIndex;
private String localCustomBaseUrl;
public SqlExecutionApi() {
this(Configuration.getDefaultApiClient());
}
public SqlExecutionApi(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 getByQueryCsvCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, final ApiCallback _callback) throws ApiException {
return getByQueryCsvCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryCsvCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, 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/Sql/csv/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (download != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("download", download));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
if (delimiter != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("delimiter", delimiter));
}
if (escape != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("escape", escape));
}
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 getByQueryCsvValidateBeforeCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryCsv(Async)");
}
return getByQueryCsvCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback, opts);
}
private ApiResponse getByQueryCsvWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape) throws ApiException {
okhttp3.Call localVarCall = getByQueryCsvValidateBeforeCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryCsvWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryCsvValidateBeforeCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryCsvAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryCsvValidateBeforeCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryCsvAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, String delimiter, String escape, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryCsvValidateBeforeCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryCsvRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Boolean download;
private Integer timeout;
private String delimiter;
private String escape;
private APIgetByQueryCsvRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set download
* @param download Makes this a file-download request (as opposed to returning the data in the response-body) (optional, default to false)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest download(Boolean download) {
this.download = download;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Set delimiter
* @param delimiter Delimiter string to override the default (optional)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest delimiter(String delimiter) {
this.delimiter = delimiter;
return this;
}
/**
* Set escape
* @param escape Escape character to override the default (optional)
* @return APIgetByQueryCsvRequest
*/
public APIgetByQueryCsvRequest escape(String escape) {
this.escape = escape;
return this;
}
/**
* Build call for getByQueryCsv
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryCsvCall(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback);
}
/**
* Execute getByQueryCsv request
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute() throws ApiException {
ApiResponse localVarResp = getByQueryCsvWithHttpInfo(query, scalarParameters, queryName, download, timeout, delimiter, escape);
return localVarResp.getData();
}
/**
* Execute getByQueryCsv request. Use any specified configuration options to override any other configuration for this request only.
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryCsvWithHttpInfo(query, scalarParameters, queryName, download, timeout, delimiter, escape, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryCsv request with HTTP info returned
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryCsvWithHttpInfo(query, scalarParameters, queryName, download, timeout, delimiter, escape);
}
/**
* Execute getByQueryCsv request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryCsvWithHttpInfo(query, scalarParameters, queryName, download, timeout, delimiter, escape, opts);
}
/**
* Execute getByQueryCsv 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryCsvAsync(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback);
}
/**
* Execute getByQueryCsv 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryCsvAsync(query, scalarParameters, queryName, download, timeout, delimiter, escape, _callback, opts);
}
}
/**
* GetByQueryCsv: Executes Sql from the url returning CSV
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryCsvRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryCsvRequest getByQueryCsv(String query) {
return new APIgetByQueryCsvRequest(query);
}
private okhttp3.Call getByQueryExcelCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
return getByQueryExcelCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryExcelCall(String query, Map scalarParameters, String queryName, Integer timeout, 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/Sql/excel/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
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 getByQueryExcelValidateBeforeCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryExcel(Async)");
}
return getByQueryExcelCall(query, scalarParameters, queryName, timeout, _callback, opts);
}
private ApiResponse getByQueryExcelWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout) throws ApiException {
okhttp3.Call localVarCall = getByQueryExcelValidateBeforeCall(query, scalarParameters, queryName, timeout, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryExcelWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryExcelValidateBeforeCall(query, scalarParameters, queryName, timeout, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryExcelAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryExcelValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryExcelAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryExcelValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryExcelRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Integer timeout;
private APIgetByQueryExcelRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryExcelRequest
*/
public APIgetByQueryExcelRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryExcelRequest
*/
public APIgetByQueryExcelRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryExcelRequest
*/
public APIgetByQueryExcelRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Build call for getByQueryExcel
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryExcelCall(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQueryExcel request
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute() throws ApiException {
ApiResponse localVarResp = getByQueryExcelWithHttpInfo(query, scalarParameters, queryName, timeout);
return localVarResp.getData();
}
/**
* Execute getByQueryExcel request. Use any specified configuration options to override any other configuration for this request only.
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryExcelWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryExcel request with HTTP info returned
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryExcelWithHttpInfo(query, scalarParameters, queryName, timeout);
}
/**
* Execute getByQueryExcel request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryExcelWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
}
/**
* Execute getByQueryExcel 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryExcelAsync(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQueryExcel 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryExcelAsync(query, scalarParameters, queryName, timeout, _callback, opts);
}
}
/**
* GetByQueryExcel: Executes Sql from the url returning an Excel file
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryExcelRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryExcelRequest getByQueryExcel(String query) {
return new APIgetByQueryExcelRequest(query);
}
private okhttp3.Call getByQueryJsonCall(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, final ApiCallback _callback) throws ApiException {
return getByQueryJsonCall(query, scalarParameters, queryName, timeout, jsonProper, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryJsonCall(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, 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/Sql/json/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
if (jsonProper != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("jsonProper", jsonProper));
}
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 getByQueryJsonValidateBeforeCall(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryJson(Async)");
}
return getByQueryJsonCall(query, scalarParameters, queryName, timeout, jsonProper, _callback, opts);
}
private ApiResponse getByQueryJsonWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper) throws ApiException {
okhttp3.Call localVarCall = getByQueryJsonValidateBeforeCall(query, scalarParameters, queryName, timeout, jsonProper, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryJsonWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryJsonValidateBeforeCall(query, scalarParameters, queryName, timeout, jsonProper, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryJsonAsync(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryJsonValidateBeforeCall(query, scalarParameters, queryName, timeout, jsonProper, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryJsonAsync(String query, Map scalarParameters, String queryName, Integer timeout, Boolean jsonProper, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryJsonValidateBeforeCall(query, scalarParameters, queryName, timeout, jsonProper, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryJsonRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Integer timeout;
private Boolean jsonProper;
private APIgetByQueryJsonRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryJsonRequest
*/
public APIgetByQueryJsonRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryJsonRequest
*/
public APIgetByQueryJsonRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryJsonRequest
*/
public APIgetByQueryJsonRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Set jsonProper
* @param jsonProper Should this be text/json (not json-encoded-as-a-string) (optional, default to false)
* @return APIgetByQueryJsonRequest
*/
public APIgetByQueryJsonRequest jsonProper(Boolean jsonProper) {
this.jsonProper = jsonProper;
return this;
}
/**
* Build call for getByQueryJson
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryJsonCall(query, scalarParameters, queryName, timeout, jsonProper, _callback);
}
/**
* Execute getByQueryJson request
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute() throws ApiException {
ApiResponse localVarResp = getByQueryJsonWithHttpInfo(query, scalarParameters, queryName, timeout, jsonProper);
return localVarResp.getData();
}
/**
* Execute getByQueryJson request. Use any specified configuration options to override any other configuration for this request only.
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryJsonWithHttpInfo(query, scalarParameters, queryName, timeout, jsonProper, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryJson request with HTTP info returned
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryJsonWithHttpInfo(query, scalarParameters, queryName, timeout, jsonProper);
}
/**
* Execute getByQueryJson request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryJsonWithHttpInfo(query, scalarParameters, queryName, timeout, jsonProper, opts);
}
/**
* Execute getByQueryJson 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryJsonAsync(query, scalarParameters, queryName, timeout, jsonProper, _callback);
}
/**
* Execute getByQueryJson 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryJsonAsync(query, scalarParameters, queryName, timeout, jsonProper, _callback, opts);
}
}
/**
* GetByQueryJson: Executes Sql from the url returning JSON
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryJsonRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryJsonRequest getByQueryJson(String query) {
return new APIgetByQueryJsonRequest(query);
}
private okhttp3.Call getByQueryParquetCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
return getByQueryParquetCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryParquetCall(String query, Map scalarParameters, String queryName, Integer timeout, 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/Sql/parquet/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
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 getByQueryParquetValidateBeforeCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryParquet(Async)");
}
return getByQueryParquetCall(query, scalarParameters, queryName, timeout, _callback, opts);
}
private ApiResponse getByQueryParquetWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout) throws ApiException {
okhttp3.Call localVarCall = getByQueryParquetValidateBeforeCall(query, scalarParameters, queryName, timeout, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryParquetWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryParquetValidateBeforeCall(query, scalarParameters, queryName, timeout, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryParquetAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryParquetValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryParquetAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryParquetValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryParquetRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Integer timeout;
private APIgetByQueryParquetRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryParquetRequest
*/
public APIgetByQueryParquetRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryParquetRequest
*/
public APIgetByQueryParquetRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryParquetRequest
*/
public APIgetByQueryParquetRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Build call for getByQueryParquet
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryParquetCall(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQueryParquet request
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute() throws ApiException {
ApiResponse localVarResp = getByQueryParquetWithHttpInfo(query, scalarParameters, queryName, timeout);
return localVarResp.getData();
}
/**
* Execute getByQueryParquet request. Use any specified configuration options to override any other configuration for this request only.
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryParquetWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryParquet request with HTTP info returned
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryParquetWithHttpInfo(query, scalarParameters, queryName, timeout);
}
/**
* Execute getByQueryParquet request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryParquetWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
}
/**
* Execute getByQueryParquet 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryParquetAsync(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQueryParquet 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryParquetAsync(query, scalarParameters, queryName, timeout, _callback, opts);
}
}
/**
* GetByQueryParquet: Executes Sql from the url returning a Parquet file
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryParquetRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryParquetRequest getByQueryParquet(String query) {
return new APIgetByQueryParquetRequest(query);
}
private okhttp3.Call getByQueryPipeCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback) throws ApiException {
return getByQueryPipeCall(query, scalarParameters, queryName, download, timeout, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryPipeCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, 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/Sql/pipe/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (download != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("download", download));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
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 getByQueryPipeValidateBeforeCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryPipe(Async)");
}
return getByQueryPipeCall(query, scalarParameters, queryName, download, timeout, _callback, opts);
}
private ApiResponse getByQueryPipeWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout) throws ApiException {
okhttp3.Call localVarCall = getByQueryPipeValidateBeforeCall(query, scalarParameters, queryName, download, timeout, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryPipeWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryPipeValidateBeforeCall(query, scalarParameters, queryName, download, timeout, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryPipeAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryPipeValidateBeforeCall(query, scalarParameters, queryName, download, timeout, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryPipeAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryPipeValidateBeforeCall(query, scalarParameters, queryName, download, timeout, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryPipeRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Boolean download;
private Integer timeout;
private APIgetByQueryPipeRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryPipeRequest
*/
public APIgetByQueryPipeRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryPipeRequest
*/
public APIgetByQueryPipeRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set download
* @param download Makes this a file-download request (as opposed to returning the data in the response-body) (optional, default to false)
* @return APIgetByQueryPipeRequest
*/
public APIgetByQueryPipeRequest download(Boolean download) {
this.download = download;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryPipeRequest
*/
public APIgetByQueryPipeRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Build call for getByQueryPipe
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryPipeCall(query, scalarParameters, queryName, download, timeout, _callback);
}
/**
* Execute getByQueryPipe request
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute() throws ApiException {
ApiResponse localVarResp = getByQueryPipeWithHttpInfo(query, scalarParameters, queryName, download, timeout);
return localVarResp.getData();
}
/**
* Execute getByQueryPipe request. Use any specified configuration options to override any other configuration for this request only.
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryPipeWithHttpInfo(query, scalarParameters, queryName, download, timeout, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryPipe request with HTTP info returned
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryPipeWithHttpInfo(query, scalarParameters, queryName, download, timeout);
}
/**
* Execute getByQueryPipe request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryPipeWithHttpInfo(query, scalarParameters, queryName, download, timeout, opts);
}
/**
* Execute getByQueryPipe 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryPipeAsync(query, scalarParameters, queryName, download, timeout, _callback);
}
/**
* Execute getByQueryPipe 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryPipeAsync(query, scalarParameters, queryName, download, timeout, _callback, opts);
}
}
/**
* GetByQueryPipe: Executes Sql from the url returning pipe-delimited
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryPipeRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryPipeRequest getByQueryPipe(String query) {
return new APIgetByQueryPipeRequest(query);
}
private okhttp3.Call getByQuerySqliteCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
return getByQuerySqliteCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQuerySqliteCall(String query, Map scalarParameters, String queryName, Integer timeout, 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/Sql/sqlite/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
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 getByQuerySqliteValidateBeforeCall(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQuerySqlite(Async)");
}
return getByQuerySqliteCall(query, scalarParameters, queryName, timeout, _callback, opts);
}
private ApiResponse getByQuerySqliteWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout) throws ApiException {
okhttp3.Call localVarCall = getByQuerySqliteValidateBeforeCall(query, scalarParameters, queryName, timeout, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQuerySqliteWithHttpInfo(String query, Map scalarParameters, String queryName, Integer timeout, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQuerySqliteValidateBeforeCall(query, scalarParameters, queryName, timeout, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQuerySqliteAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQuerySqliteValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQuerySqliteAsync(String query, Map scalarParameters, String queryName, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQuerySqliteValidateBeforeCall(query, scalarParameters, queryName, timeout, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQuerySqliteRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Integer timeout;
private APIgetByQuerySqliteRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQuerySqliteRequest
*/
public APIgetByQuerySqliteRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQuerySqliteRequest
*/
public APIgetByQuerySqliteRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQuerySqliteRequest
*/
public APIgetByQuerySqliteRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Build call for getByQuerySqlite
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQuerySqliteCall(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQuerySqlite request
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute() throws ApiException {
ApiResponse localVarResp = getByQuerySqliteWithHttpInfo(query, scalarParameters, queryName, timeout);
return localVarResp.getData();
}
/**
* Execute getByQuerySqlite request. Use any specified configuration options to override any other configuration for this request only.
* @return File
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public File execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQuerySqliteWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
return localVarResp.getData();
}
/**
* Execute getByQuerySqlite request with HTTP info returned
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQuerySqliteWithHttpInfo(query, scalarParameters, queryName, timeout);
}
/**
* Execute getByQuerySqlite request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<File>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQuerySqliteWithHttpInfo(query, scalarParameters, queryName, timeout, opts);
}
/**
* Execute getByQuerySqlite 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQuerySqliteAsync(query, scalarParameters, queryName, timeout, _callback);
}
/**
* Execute getByQuerySqlite 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQuerySqliteAsync(query, scalarParameters, queryName, timeout, _callback, opts);
}
}
/**
* GetByQuerySqlite: Executes Sql from the url returning SqLite DB
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQuerySqliteRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQuerySqliteRequest getByQuerySqlite(String query) {
return new APIgetByQuerySqliteRequest(query);
}
private okhttp3.Call getByQueryXmlCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback) throws ApiException {
return getByQueryXmlCall(query, scalarParameters, queryName, download, timeout, _callback, new ConfigurationOptions());
}
private okhttp3.Call getByQueryXmlCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, 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/Sql/xml/{query}"
.replace("{" + "query" + "}", localVarApiClient.escapeString(query.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (download != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("download", download));
}
if (timeout != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeout", timeout));
}
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 getByQueryXmlValidateBeforeCall(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'query' is set
if (query == null) {
throw new ApiException("Missing the required parameter 'query' when calling getByQueryXml(Async)");
}
return getByQueryXmlCall(query, scalarParameters, queryName, download, timeout, _callback, opts);
}
private ApiResponse getByQueryXmlWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout) throws ApiException {
okhttp3.Call localVarCall = getByQueryXmlValidateBeforeCall(query, scalarParameters, queryName, download, timeout, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse getByQueryXmlWithHttpInfo(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryXmlValidateBeforeCall(query, scalarParameters, queryName, download, timeout, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call getByQueryXmlAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getByQueryXmlValidateBeforeCall(query, scalarParameters, queryName, download, timeout, _callback, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
private okhttp3.Call getByQueryXmlAsync(String query, Map scalarParameters, String queryName, Boolean download, Integer timeout, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = getByQueryXmlValidateBeforeCall(query, scalarParameters, queryName, download, timeout, _callback, opts);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
public class APIgetByQueryXmlRequest {
private final String query;
private Map scalarParameters;
private String queryName;
private Boolean download;
private Integer timeout;
private APIgetByQueryXmlRequest(String query) {
this.query = query;
}
/**
* Set scalarParameters
* @param scalarParameters Json encoded dictionary of key-value pairs for scalar parameter values to use in the sql execution. (optional)
* @return APIgetByQueryXmlRequest
*/
public APIgetByQueryXmlRequest scalarParameters(Map scalarParameters) {
this.scalarParameters = scalarParameters;
return this;
}
/**
* Set queryName
* @param queryName Name to apply to the query in logs and `Sys.Logs.HcQueryStart` (optional)
* @return APIgetByQueryXmlRequest
*/
public APIgetByQueryXmlRequest queryName(String queryName) {
this.queryName = queryName;
return this;
}
/**
* Set download
* @param download Makes this a file-download request (as opposed to returning the data in the response-body) (optional, default to false)
* @return APIgetByQueryXmlRequest
*/
public APIgetByQueryXmlRequest download(Boolean download) {
this.download = download;
return this;
}
/**
* Set timeout
* @param timeout In seconds: <0 → ∞, 0 → 120s (optional, default to 0)
* @return APIgetByQueryXmlRequest
*/
public APIgetByQueryXmlRequest timeout(Integer timeout) {
this.timeout = timeout;
return this;
}
/**
* Build call for getByQueryXml
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call buildCall(final ApiCallback _callback) throws ApiException {
return getByQueryXmlCall(query, scalarParameters, queryName, download, timeout, _callback);
}
/**
* Execute getByQueryXml request
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute() throws ApiException {
ApiResponse localVarResp = getByQueryXmlWithHttpInfo(query, scalarParameters, queryName, download, timeout);
return localVarResp.getData();
}
/**
* Execute getByQueryXml request. Use any specified configuration options to override any other configuration for this request only.
* @return String
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public String execute(ConfigurationOptions opts) throws ApiException {
ApiResponse localVarResp = getByQueryXmlWithHttpInfo(query, scalarParameters, queryName, download, timeout, opts);
return localVarResp.getData();
}
/**
* Execute getByQueryXml request with HTTP info returned
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo() throws ApiException {
return getByQueryXmlWithHttpInfo(query, scalarParameters, queryName, download, timeout);
}
/**
* Execute getByQueryXml request with HTTP info returned. Use any specified configuration options to override any other configuration for this request only.
* @return ApiResponse<String>
* @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
-
400
Bad Request
-
403
Forbidden
-
*/
public ApiResponse executeWithHttpInfo(ConfigurationOptions opts) throws ApiException {
return getByQueryXmlWithHttpInfo(query, scalarParameters, queryName, download, timeout, opts);
}
/**
* Execute getByQueryXml 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback) throws ApiException {
return getByQueryXmlAsync(query, scalarParameters, queryName, download, timeout, _callback);
}
/**
* Execute getByQueryXml 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
-
400
Bad Request
-
403
Forbidden
-
*/
public okhttp3.Call executeAsync(final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
return getByQueryXmlAsync(query, scalarParameters, queryName, download, timeout, _callback, opts);
}
}
/**
* GetByQueryXml: Executes Sql from the url returning XML
* Returns data from a simple single-line query execution which is specified on the url. e.g. `select ^ from Sys.Field order by 1, 2`, returned in the format of the method name. The following error codes are to be anticipated with standard Problem Detail reports: - 400 BadRequest - something failed with the execution or parsing of your query - 401 Unauthorized - 403 Forbidden
* @param query LuminesceSql to Execute (must be one line only) (required)
* @return APIgetByQueryXmlRequest
* @http.response.details
Status Code
Description
Response Headers
200
Success
-
400
Bad Request
-
403
Forbidden
-
*/
public APIgetByQueryXmlRequest getByQueryXml(String query) {
return new APIgetByQueryXmlRequest(query);
}
private okhttp3.Call putByQueryCsvCall(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape, final ApiCallback _callback) throws ApiException {
return putByQueryCsvCall(body, scalarParameters, queryName, download, timeoutSeconds, delimiter, escape, _callback, new ConfigurationOptions());
}
private okhttp3.Call putByQueryCsvCall(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape, 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/Sql/csv";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (scalarParameters != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("scalarParameters", scalarParameters));
}
if (queryName != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("queryName", queryName));
}
if (download != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("download", download));
}
if (timeoutSeconds != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("timeoutSeconds", timeoutSeconds));
}
if (delimiter != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("delimiter", delimiter));
}
if (escape != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("escape", escape));
}
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 putByQueryCsvValidateBeforeCall(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape, final ApiCallback _callback, ConfigurationOptions opts) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling putByQueryCsv(Async)");
}
return putByQueryCsvCall(body, scalarParameters, queryName, download, timeoutSeconds, delimiter, escape, _callback, opts);
}
private ApiResponse putByQueryCsvWithHttpInfo(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape) throws ApiException {
okhttp3.Call localVarCall = putByQueryCsvValidateBeforeCall(body, scalarParameters, queryName, download, timeoutSeconds, delimiter, escape, null, new ConfigurationOptions());
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private ApiResponse putByQueryCsvWithHttpInfo(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape, ConfigurationOptions opts) throws ApiException {
okhttp3.Call localVarCall = putByQueryCsvValidateBeforeCall(body, scalarParameters, queryName, download, timeoutSeconds, delimiter, escape, null, opts);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
private okhttp3.Call putByQueryCsvAsync(String body, Map scalarParameters, String queryName, Boolean download, Integer timeoutSeconds, String delimiter, String escape, final ApiCallback