internal virtual ListTopicsDetectionJobsResponse ListTopicsDetectionJobs(ListTopicsDetectionJobsRequest request) { var marshaller = new ListTopicsDetectionJobsRequestMarshaller(); var unmarshaller = ListTopicsDetectionJobsResponseUnmarshaller.Instance; return(Invoke <ListTopicsDetectionJobsRequest, ListTopicsDetectionJobsResponse>(request, marshaller, unmarshaller)); }
public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonComprehendConfig config = new AmazonComprehendConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonComprehendClient client = new AmazonComprehendClient(creds, config); ListTopicsDetectionJobsResponse resp = new ListTopicsDetectionJobsResponse(); do { ListTopicsDetectionJobsRequest req = new ListTopicsDetectionJobsRequest { NextToken = resp.NextToken , MaxResults = maxItems }; resp = client.ListTopicsDetectionJobs(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.TopicsDetectionJobPropertiesList) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.NextToken)); }
/// <summary> /// Initiates the asynchronous execution of the ListTopicsDetectionJobs operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the ListTopicsDetectionJobs operation.</param> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> /// <returns>The task object representing the asynchronous operation.</returns> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/comprehend-2017-11-27/ListTopicsDetectionJobs">REST API Reference for ListTopicsDetectionJobs Operation</seealso> public virtual Task <ListTopicsDetectionJobsResponse> ListTopicsDetectionJobsAsync(ListTopicsDetectionJobsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new ListTopicsDetectionJobsRequestMarshaller(); var unmarshaller = ListTopicsDetectionJobsResponseUnmarshaller.Instance; return(InvokeAsync <ListTopicsDetectionJobsRequest, ListTopicsDetectionJobsResponse>(request, marshaller, unmarshaller, cancellationToken)); }