Amazon.IdentityManagement.AmazonIdentityManagementServiceClient.GetSSHPublicKeyAsync C# (CSharp) Method

GetSSHPublicKeyAsync() public method

Initiates the asynchronous execution of the GetSSHPublicKey operation.
public GetSSHPublicKeyAsync ( GetSSHPublicKeyRequest request, GetSSHPublicKeyResponse>.AmazonServiceCallback callback, AsyncOptions options = null ) : void
request GetSSHPublicKeyRequest Container for the necessary parameters to execute the GetSSHPublicKey operation on AmazonIdentityManagementServiceClient.
callback GetSSHPublicKeyResponse>.AmazonServiceCallback An Action delegate that is invoked when the operation completes.
options AsyncOptions A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback /// procedure using the AsyncState property.
return void
        public void GetSSHPublicKeyAsync(GetSSHPublicKeyRequest request, AmazonServiceCallback<GetSSHPublicKeyRequest, GetSSHPublicKeyResponse> callback, AsyncOptions options = null)
        {
            options = options == null?new AsyncOptions():options;
            var marshaller = new GetSSHPublicKeyRequestMarshaller();
            var unmarshaller = GetSSHPublicKeyResponseUnmarshaller.Instance;
            Action<AmazonWebServiceRequest, AmazonWebServiceResponse, Exception, AsyncOptions> callbackHelper = null;
            if(callback !=null )
                callbackHelper = (AmazonWebServiceRequest req, AmazonWebServiceResponse res, Exception ex, AsyncOptions ao) => { 
                    AmazonServiceResult<GetSSHPublicKeyRequest,GetSSHPublicKeyResponse> responseObject 
                            = new AmazonServiceResult<GetSSHPublicKeyRequest,GetSSHPublicKeyResponse>((GetSSHPublicKeyRequest)req, (GetSSHPublicKeyResponse)res, ex , ao.State);    
                        callback(responseObject); 
                };
            BeginInvoke<GetSSHPublicKeyRequest>(request, marshaller, unmarshaller, options, callbackHelper);
        }

Same methods

AmazonIdentityManagementServiceClient::GetSSHPublicKeyAsync ( GetSSHPublicKeyRequest request, System cancellationToken = default(CancellationToken) ) : Task
AmazonIdentityManagementServiceClient