Exemple #1
0
        internal virtual GetCognitoEventsResponse GetCognitoEvents(GetCognitoEventsRequest request)
        {
            var marshaller   = GetCognitoEventsRequestMarshaller.Instance;
            var unmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;

            return(Invoke <GetCognitoEventsRequest, GetCognitoEventsResponse>(request, marshaller, unmarshaller));
        }
Exemple #2
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetCognitoEvents operation.
        /// </summary>
        ///
        /// <param name="request">Container for the necessary parameters to execute the GetCognitoEvents 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/cognito-sync-2014-06-30/GetCognitoEvents">REST API Reference for GetCognitoEvents Operation</seealso>
        public virtual Task <GetCognitoEventsResponse> GetCognitoEventsAsync(GetCognitoEventsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller   = GetCognitoEventsRequestMarshaller.Instance;
            var unmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;

            return(InvokeAsync <GetCognitoEventsRequest, GetCognitoEventsResponse>(request, marshaller,
                                                                                   unmarshaller, cancellationToken));
        }
Exemple #3
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetCognitoEvents operation.
        /// </summary>
        ///
        /// <param name="request">Container for the necessary parameters to execute the GetCognitoEvents 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/cognito-sync-2014-06-30/GetCognitoEvents">REST API Reference for GetCognitoEvents Operation</seealso>
        public virtual Task <GetCognitoEventsResponse> GetCognitoEventsAsync(GetCognitoEventsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var options = new InvokeOptions();

            options.RequestMarshaller    = GetCognitoEventsRequestMarshaller.Instance;
            options.ResponseUnmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;

            return(InvokeAsync <GetCognitoEventsResponse>(request, options, cancellationToken));
        }
Exemple #4
0
        internal virtual GetCognitoEventsResponse GetCognitoEvents(GetCognitoEventsRequest request)
        {
            var options = new InvokeOptions();

            options.RequestMarshaller    = GetCognitoEventsRequestMarshaller.Instance;
            options.ResponseUnmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;

            return(Invoke <GetCognitoEventsResponse>(request, options));
        }
Exemple #5
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetCognitoEvents operation.
        /// </summary>
        ///
        /// <param name="request">Container for the necessary parameters to execute the GetCognitoEvents operation on AmazonCognitoSyncClient.</param>
        /// <param name="callback">An Action delegate that is invoked when the operation completes.</param>
        /// <param name="options">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>
        public void GetCognitoEventsAsync(GetCognitoEventsRequest request, AmazonServiceCallback <GetCognitoEventsRequest, GetCognitoEventsResponse> callback, AsyncOptions options = null)
        {
            options = options == null?new AsyncOptions():options;
            var marshaller   = new GetCognitoEventsRequestMarshaller();
            var unmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;
            Action <AmazonWebServiceRequest, AmazonWebServiceResponse, Exception, AsyncOptions> callbackHelper = null;

            if (callback != null)
            {
                callbackHelper = (AmazonWebServiceRequest req, AmazonWebServiceResponse res, Exception ex, AsyncOptions ao) => {
                    AmazonServiceResult <GetCognitoEventsRequest, GetCognitoEventsResponse> responseObject
                        = new AmazonServiceResult <GetCognitoEventsRequest, GetCognitoEventsResponse>((GetCognitoEventsRequest)req, (GetCognitoEventsResponse)res, ex, ao.State);
                    callback(responseObject);
                }
            }
            ;
            BeginInvoke <GetCognitoEventsRequest>(request, marshaller, unmarshaller, options, callbackHelper);
        }