コード例 #1
0
        public void SnowballGetJobUnlockCode()
        {
            #region to-get-the-unlock-code-for-a-job-youve-created-for-aws-snowball-1482541987286

            var response = client.GetJobUnlockCode(new GetJobUnlockCodeRequest
            {
                JobId = "JID123e4567-e89b-12d3-a456-426655440000"
            });

            string unlockCode = response.UnlockCode;

            #endregion
        }
コード例 #2
0
 private Amazon.Snowball.Model.GetJobUnlockCodeResponse CallAWSServiceOperation(IAmazonSnowball client, Amazon.Snowball.Model.GetJobUnlockCodeRequest request)
 {
     Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "AWS Import/Export Snowball", "GetJobUnlockCode");
     try
     {
         #if DESKTOP
         return(client.GetJobUnlockCode(request));
         #elif CORECLR
         return(client.GetJobUnlockCodeAsync(request).GetAwaiter().GetResult());
         #else
                 #error "Unknown build edition"
         #endif
     }
     catch (AmazonServiceException exc)
     {
         var webException = exc.InnerException as System.Net.WebException;
         if (webException != null)
         {
             throw new Exception(Utils.Common.FormatNameResolutionFailureMessage(client.Config, webException.Message), webException);
         }
         throw;
     }
 }