public virtual IList <SchemaLogEntryDto> querySchemaLog(SchemaLogQueryDto dto, int?firstResult, int?maxResults) { SchemaLogQuery query = dto.toQuery(processEngine); IList <SchemaLogEntry> schemaLogEntries; if (firstResult != null || maxResults != null) { schemaLogEntries = executePaginatedQuery(query, firstResult, maxResults); } else { schemaLogEntries = query.list(); } return(SchemaLogEntryDto.fromSchemaLogEntries(schemaLogEntries)); }
/// <summary> /// Queries for schema log entries that fulfill given parameters. /// </summary> /// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="firstResult">Pagination of results. Specifies the index of the first result to return. (optional)</param> /// <param name="maxResults">Pagination of results. Specifies the maximum number of results to return. Will return less results if there are no more results left. (optional)</param> /// <param name="schemaLogQueryDto"> (optional)</param> /// <returns>Task of ApiResponse (List<SchemaLogEntryDto>)</returns> public async System.Threading.Tasks.Task <ApiResponse <List <SchemaLogEntryDto> > > QuerySchemaLogAsyncWithHttpInfo(int?firstResult = default(int?), int?maxResults = default(int?), SchemaLogQueryDto schemaLogQueryDto = default(SchemaLogQueryDto)) { var localVarPath = "/schema/log"; var localVarPathParams = new Dictionary <String, String>(); var localVarQueryParams = new List <KeyValuePair <String, String> >(); var localVarHeaderParams = new Dictionary <String, String>(this.Configuration.DefaultHeader); var localVarFormParams = new Dictionary <String, String>(); var localVarFileParams = new Dictionary <String, FileParameter>(); Object localVarPostBody = null; // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); // to determine the Accept header String[] localVarHttpHeaderAccepts = new String[] { "application/json" }; String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); if (localVarHttpHeaderAccept != null) { localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); } if (firstResult != null) { localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "firstResult", firstResult)); // query parameter } if (maxResults != null) { localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "maxResults", maxResults)); // query parameter } if (schemaLogQueryDto != null && schemaLogQueryDto.GetType() != typeof(byte[])) { localVarPostBody = this.Configuration.ApiClient.Serialize(schemaLogQueryDto); // http body (model) parameter } else { localVarPostBody = schemaLogQueryDto; // byte array } // make the HTTP request IRestResponse localVarResponse = (IRestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath, Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType); int localVarStatusCode = (int)localVarResponse.StatusCode; if (ExceptionFactory != null) { Exception exception = ExceptionFactory("QuerySchemaLog", localVarResponse); if (exception != null) { throw exception; } } return(new ApiResponse <List <SchemaLogEntryDto> >(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), (List <SchemaLogEntryDto>) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List <SchemaLogEntryDto>)))); }
/// <summary> /// Queries for schema log entries that fulfill given parameters. /// </summary> /// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="firstResult">Pagination of results. Specifies the index of the first result to return. (optional)</param> /// <param name="maxResults">Pagination of results. Specifies the maximum number of results to return. Will return less results if there are no more results left. (optional)</param> /// <param name="schemaLogQueryDto"> (optional)</param> /// <returns>Task of List<SchemaLogEntryDto></returns> public async System.Threading.Tasks.Task <List <SchemaLogEntryDto> > QuerySchemaLogAsync(int?firstResult = default(int?), int?maxResults = default(int?), SchemaLogQueryDto schemaLogQueryDto = default(SchemaLogQueryDto)) { ApiResponse <List <SchemaLogEntryDto> > localVarResponse = await QuerySchemaLogAsyncWithHttpInfo(firstResult, maxResults, schemaLogQueryDto); return(localVarResponse.Data); }
/// <summary> /// Queries for schema log entries that fulfill given parameters. /// </summary> /// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="firstResult">Pagination of results. Specifies the index of the first result to return. (optional)</param> /// <param name="maxResults">Pagination of results. Specifies the maximum number of results to return. Will return less results if there are no more results left. (optional)</param> /// <param name="schemaLogQueryDto"> (optional)</param> /// <returns>List<SchemaLogEntryDto></returns> public List <SchemaLogEntryDto> QuerySchemaLog(int?firstResult = default(int?), int?maxResults = default(int?), SchemaLogQueryDto schemaLogQueryDto = default(SchemaLogQueryDto)) { ApiResponse <List <SchemaLogEntryDto> > localVarResponse = QuerySchemaLogWithHttpInfo(firstResult, maxResults, schemaLogQueryDto); return(localVarResponse.Data); }
/// <summary> /// Queries for schema log entries that fulfill given parameters. /// </summary> /// <exception cref="Camunda.OpenApi.Client.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="firstResult">Pagination of results. Specifies the index of the first result to return. (optional)</param> /// <param name="maxResults">Pagination of results. Specifies the maximum number of results to return. Will return less results if there are no more results left. (optional)</param> /// <param name="schemaLogQueryDto"> (optional)</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <returns>Task of ApiResponse (List<SchemaLogEntryDto>)</returns> public async System.Threading.Tasks.Task <Camunda.OpenApi.Client.Client.ApiResponse <List <SchemaLogEntryDto> > > QuerySchemaLogWithHttpInfoAsync(int?firstResult = default(int?), int?maxResults = default(int?), SchemaLogQueryDto schemaLogQueryDto = default(SchemaLogQueryDto), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { Camunda.OpenApi.Client.Client.RequestOptions localVarRequestOptions = new Camunda.OpenApi.Client.Client.RequestOptions(); String[] _contentTypes = new String[] { "application/json" }; // to determine the Accept header String[] _accepts = new String[] { "application/json" }; var localVarContentType = Camunda.OpenApi.Client.Client.ClientUtils.SelectHeaderContentType(_contentTypes); if (localVarContentType != null) { localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); } var localVarAccept = Camunda.OpenApi.Client.Client.ClientUtils.SelectHeaderAccept(_accepts); if (localVarAccept != null) { localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } if (firstResult != null) { localVarRequestOptions.QueryParameters.Add(Camunda.OpenApi.Client.Client.ClientUtils.ParameterToMultiMap("", "firstResult", firstResult)); } if (maxResults != null) { localVarRequestOptions.QueryParameters.Add(Camunda.OpenApi.Client.Client.ClientUtils.ParameterToMultiMap("", "maxResults", maxResults)); } localVarRequestOptions.Data = schemaLogQueryDto; // make the HTTP request var localVarResponse = await this.AsynchronousClient.PostAsync <List <SchemaLogEntryDto> >("/schema/log", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("QuerySchemaLog", localVarResponse); if (_exception != null) { throw _exception; } } return(localVarResponse); }
/// <summary> /// Queries for schema log entries that fulfill given parameters. /// </summary> /// <exception cref="Camunda.OpenApi.Client.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="firstResult">Pagination of results. Specifies the index of the first result to return. (optional)</param> /// <param name="maxResults">Pagination of results. Specifies the maximum number of results to return. Will return less results if there are no more results left. (optional)</param> /// <param name="schemaLogQueryDto"> (optional)</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <returns>Task of List<SchemaLogEntryDto></returns> public async System.Threading.Tasks.Task <List <SchemaLogEntryDto> > QuerySchemaLogAsync(int?firstResult = default(int?), int?maxResults = default(int?), SchemaLogQueryDto schemaLogQueryDto = default(SchemaLogQueryDto), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { Camunda.OpenApi.Client.Client.ApiResponse <List <SchemaLogEntryDto> > localVarResponse = await QuerySchemaLogWithHttpInfoAsync(firstResult, maxResults, schemaLogQueryDto, cancellationToken).ConfigureAwait(false); return(localVarResponse.Data); }