public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonCodeGuruReviewerConfig config = new AmazonCodeGuruReviewerConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonCodeGuruReviewerClient client = new AmazonCodeGuruReviewerClient(creds, config); ListRepositoryAssociationsResponse resp = new ListRepositoryAssociationsResponse(); do { ListRepositoryAssociationsRequest req = new ListRepositoryAssociationsRequest { NextToken = resp.NextToken , MaxResults = maxItems }; resp = client.ListRepositoryAssociations(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.RepositoryAssociationSummaries) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.NextToken)); }
/// <summary> /// Initiates the asynchronous execution of the ListRepositoryAssociations operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the ListRepositoryAssociations operation on AmazonCodeGuruReviewerClient.</param> /// <param name="callback">An AsyncCallback delegate that is invoked when the operation completes.</param> /// <param name="state">A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback /// procedure using the AsyncState property.</param> /// /// <returns>An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndListRepositoryAssociations /// operation.</returns> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/codeguru-reviewer-2019-09-19/ListRepositoryAssociations">REST API Reference for ListRepositoryAssociations Operation</seealso> public virtual IAsyncResult BeginListRepositoryAssociations(ListRepositoryAssociationsRequest request, AsyncCallback callback, object state) { var options = new InvokeOptions(); options.RequestMarshaller = ListRepositoryAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListRepositoryAssociationsResponseUnmarshaller.Instance; return(BeginInvoke(request, options, callback, state)); }
/// <summary> /// Lists repository associations. You can optionally filter on one or more of the following /// recommendation properties: provider types, states, names, and owners. /// </summary> /// <param name="request">Container for the necessary parameters to execute the ListRepositoryAssociations service method.</param> /// /// <returns>The response from the ListRepositoryAssociations service method, as returned by CodeGuruReviewer.</returns> /// <exception cref="Amazon.CodeGuruReviewer.Model.InternalServerException"> /// The server encountered an internal error and is unable to complete the request. /// </exception> /// <exception cref="Amazon.CodeGuruReviewer.Model.ThrottlingException"> /// The request was denied due to request throttling. /// </exception> /// <exception cref="Amazon.CodeGuruReviewer.Model.ValidationException"> /// The input fails to satisfy the specified constraints. /// </exception> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/codeguru-reviewer-2019-09-19/ListRepositoryAssociations">REST API Reference for ListRepositoryAssociations Operation</seealso> public virtual ListRepositoryAssociationsResponse ListRepositoryAssociations(ListRepositoryAssociationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListRepositoryAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListRepositoryAssociationsResponseUnmarshaller.Instance; return(Invoke <ListRepositoryAssociationsResponse>(request, options)); }
/// <summary> /// Lists repository associations. You can optionally filter on one or more of the following /// recommendation properties: provider types, states, names, and owners. /// </summary> /// <param name="request">Container for the necessary parameters to execute the ListRepositoryAssociations service method.</param> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> /// /// <returns>The response from the ListRepositoryAssociations service method, as returned by CodeGuruReviewer.</returns> /// <exception cref="Amazon.CodeGuruReviewer.Model.InternalServerException"> /// The server encountered an internal error and is unable to complete the request. /// </exception> /// <exception cref="Amazon.CodeGuruReviewer.Model.ThrottlingException"> /// The request was denied due to request throttling. /// </exception> /// <exception cref="Amazon.CodeGuruReviewer.Model.ValidationException"> /// The input fails to satisfy the specified constraints. /// </exception> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/codeguru-reviewer-2019-09-19/ListRepositoryAssociations">REST API Reference for ListRepositoryAssociations Operation</seealso> public virtual Task <ListRepositoryAssociationsResponse> ListRepositoryAssociationsAsync(ListRepositoryAssociationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListRepositoryAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListRepositoryAssociationsResponseUnmarshaller.Instance; return(InvokeAsync <ListRepositoryAssociationsResponse>(request, options, cancellationToken)); }