Beispiel #1
0
        /// <summary>
        /// <para>Returns the user's current activity limits.</para>
        /// </summary>
        ///
        /// <param name="getSendQuotaRequest">Container for the necessary
        ///           parameters to execute the GetSendQuota service method on
        ///           AmazonSimpleEmailService.</param>
        ///
        /// <returns>The response from the GetSendQuota service method, as
        ///         returned by AmazonSimpleEmailService.</returns>
        ///
        public GetSendQuotaResponse GetSendQuota(GetSendQuotaRequest getSendQuotaRequest)
        {
            IRequest <GetSendQuotaRequest> request  = new GetSendQuotaRequestMarshaller().Marshall(getSendQuotaRequest);
            GetSendQuotaResponse           response = Invoke <GetSendQuotaRequest, GetSendQuotaResponse> (request, this.signer, GetSendQuotaResponseUnmarshaller.GetInstance());

            return(response);
        }
Beispiel #2
0
        /// <summary>
        /// <para>Returns the user's current sending limits.</para> <para>This action is throttled at one request per second.</para>
        /// </summary>
        ///
        /// <param name="getSendQuotaRequest">Container for the necessary parameters to execute the GetSendQuota service method on
        /// AmazonSimpleEmailService.</param>
        ///
        /// <returns>The response from the GetSendQuota service method, as returned by AmazonSimpleEmailService.</returns>
        /// <param name="cancellationToken">
        ///     A cancellation token that can be used by other objects or threads to receive notice of cancellation.
        /// </param>
        public Task <GetSendQuotaResponse> GetSendQuotaAsync(GetSendQuotaRequest getSendQuotaRequest, CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller   = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.GetInstance();

            return(Invoke <IRequest, GetSendQuotaRequest, GetSendQuotaResponse>(getSendQuotaRequest, marshaller, unmarshaller, signer, cancellationToken));
        }
Beispiel #3
0
        internal GetSendQuotaResponse GetSendQuota(GetSendQuotaRequest request)
        {
            var marshaller   = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return(Invoke <GetSendQuotaRequest, GetSendQuotaResponse>(request, marshaller, unmarshaller));
        }
Beispiel #4
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetSendQuota operation.
        /// </summary>
        ///
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota 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>
        public Task <GetSendQuotaResponse> GetSendQuotaAsync(GetSendQuotaRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller   = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return(InvokeAsync <GetSendQuotaRequest, GetSendQuotaResponse>(request, marshaller,
                                                                           unmarshaller, cancellationToken));
        }
Beispiel #5
0
        IAsyncResult invokeGetSendQuota(GetSendQuotaRequest getSendQuotaRequest, AsyncCallback callback, object state, bool synchronized)
        {
            IRequest    irequest     = new GetSendQuotaRequestMarshaller().Marshall(getSendQuotaRequest);
            var         unmarshaller = GetSendQuotaResponseUnmarshaller.GetInstance();
            AsyncResult result       = new AsyncResult(irequest, callback, state, synchronized, signer, unmarshaller);

            Invoke(result);
            return(result);
        }
Beispiel #6
0
        public void GetSendQuotaMarshallTest()
        {
            var operation = service_model.FindOperation("GetSendQuota");

            var request         = InstantiateClassGenerator.Execute <GetSendQuotaRequest>();
            var marshaller      = new GetSendQuotaRequestMarshaller();
            var internalRequest = marshaller.Marshall(request);
            var validator       = new AWSQueryValidator(internalRequest.Parameters, request, service_model, operation);

            validator.Validate();


            var payloadResponse = new XmlSampleGenerator(service_model, operation).Execute();
            var context         = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response        = GetSendQuotaResponseUnmarshaller.Instance.Unmarshall(context)
                                  as GetSendQuotaResponse;

            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);
        }
        /// <summary>
        /// Initiates the asynchronous execution of the GetSendQuota operation.
        /// <seealso cref="Amazon.SimpleEmail.IAmazonSimpleEmailService.GetSendQuota"/>
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota 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>
		public Task<GetSendQuotaResponse> GetSendQuotaAsync(GetSendQuotaRequest request, CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.GetInstance();
            return Invoke<IRequest, GetSendQuotaRequest, GetSendQuotaResponse>(request, marshaller, unmarshaller, signer, cancellationToken);
        }
        /// <summary>
        /// Initiates the asynchronous execution of the GetSendQuota operation.
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota 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>
        public Task<GetSendQuotaResponse> GetSendQuotaAsync(GetSendQuotaRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return InvokeAsync<GetSendQuotaRequest,GetSendQuotaResponse>(request, marshaller, 
                unmarshaller, cancellationToken);
        }
        /// <summary>
        /// Returns the user's current sending limits.
        /// 
        ///  
        /// <para>
        /// This action is throttled at one request per second.
        /// </para>
        /// </summary>
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota service method.</param>
        /// 
        /// <returns>The response from the GetSendQuota service method, as returned by SimpleEmailService.</returns>
        public GetSendQuotaResponse GetSendQuota(GetSendQuotaRequest request)
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return Invoke<GetSendQuotaRequest,GetSendQuotaResponse>(request, marshaller, unmarshaller);
        }
        /// <summary>
        /// Initiates the asynchronous execution of the GetSendQuota operation.
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota operation on AmazonSimpleEmailServiceClient.</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 EndGetSendQuota
        ///         operation.</returns>
        public IAsyncResult BeginGetSendQuota(GetSendQuotaRequest request, AsyncCallback callback, object state)
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return BeginInvoke<GetSendQuotaRequest>(request, marshaller, unmarshaller,
                callback, state);
        }
 IAsyncResult invokeGetSendQuota(GetSendQuotaRequest getSendQuotaRequest, AsyncCallback callback, object state, bool synchronized)
 {
     IRequest irequest = new GetSendQuotaRequestMarshaller().Marshall(getSendQuotaRequest);
     var unmarshaller = GetSendQuotaResponseUnmarshaller.GetInstance();
     AsyncResult result = new AsyncResult(irequest, callback, state, synchronized, signer, unmarshaller);
     Invoke(result);
     return result;
 }
        IAsyncResult invokeGetSendQuota(GetSendQuotaRequest request, AsyncCallback callback, object state, bool synchronized)
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;

            return Invoke(request, callback, state, synchronized, marshaller, unmarshaller, signer);
        }
        public void GetSendQuotaMarshallTest()
        {
            var operation = service_model.FindOperation("GetSendQuota");

            var request = InstantiateClassGenerator.Execute<GetSendQuotaRequest>();
            var marshaller = new GetSendQuotaRequestMarshaller();
            var internalRequest = marshaller.Marshall(request);
            var validator = new AWSQueryValidator(internalRequest.Parameters, request, service_model, operation);
            validator.Validate();


            var payloadResponse = new XmlSampleGenerator(service_model, operation).Execute();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = GetSendQuotaResponseUnmarshaller.Instance.Unmarshall(context)
                as GetSendQuotaResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
        /// <summary>
        /// Initiates the asynchronous execution of the GetSendQuota operation.
        /// <seealso cref="Amazon.SimpleEmail.IAmazonSimpleEmailService.GetSendQuota"/>
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetSendQuota 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>
		public async Task<GetSendQuotaResponse> GetSendQuotaAsync(GetSendQuotaRequest request, CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller = new GetSendQuotaRequestMarshaller();
            var unmarshaller = GetSendQuotaResponseUnmarshaller.GetInstance();
            var response = await Invoke<IRequest, GetSendQuotaRequest, GetSendQuotaResponse>(request, marshaller, unmarshaller, signer, cancellationToken)
                .ConfigureAwait(continueOnCapturedContext: false);
            return response;
        }
  /// <summary>
  /// <para>Returns the user's current activity limits.</para>
  /// </summary>
  /// 
  /// <param name="getSendQuotaRequest">Container for the necessary
  ///           parameters to execute the GetSendQuota service method on
  ///           AmazonSimpleEmailService.</param>
  /// 
  /// <returns>The response from the GetSendQuota service method, as
  ///         returned by AmazonSimpleEmailService.</returns>
  /// 
 public GetSendQuotaResponse GetSendQuota(GetSendQuotaRequest getSendQuotaRequest) 
 {           
     IRequest<GetSendQuotaRequest> request = new GetSendQuotaRequestMarshaller().Marshall(getSendQuotaRequest);
     GetSendQuotaResponse response = Invoke<GetSendQuotaRequest, GetSendQuotaResponse> (request, this.signer, GetSendQuotaResponseUnmarshaller.GetInstance());
     return response;
 }
 /// <summary>
 /// Initiates the asynchronous execution of the GetSendQuota operation.
 /// </summary>
 /// 
 /// <param name="request">Container for the necessary parameters to execute the GetSendQuota operation on AmazonSimpleEmailServiceClient.</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 GetSendQuotaAsync(GetSendQuotaRequest request, AmazonServiceCallback<GetSendQuotaRequest, GetSendQuotaResponse> callback, AsyncOptions options = null)
 {
     options = options == null?new AsyncOptions():options;
     var marshaller = new GetSendQuotaRequestMarshaller();
     var unmarshaller = GetSendQuotaResponseUnmarshaller.Instance;
     Action<AmazonWebServiceRequest, AmazonWebServiceResponse, Exception, AsyncOptions> callbackHelper = null;
     if(callback !=null )
         callbackHelper = (AmazonWebServiceRequest req, AmazonWebServiceResponse res, Exception ex, AsyncOptions ao) => { 
             AmazonServiceResult<GetSendQuotaRequest,GetSendQuotaResponse> responseObject 
                     = new AmazonServiceResult<GetSendQuotaRequest,GetSendQuotaResponse>((GetSendQuotaRequest)req, (GetSendQuotaResponse)res, ex , ao.State);    
                 callback(responseObject); 
         };
     BeginInvoke<GetSendQuotaRequest>(request, marshaller, unmarshaller, options, callbackHelper);
 }