Пример #1
0
        public void StorageGatewayListVolumeRecoveryPoints()
        {
            #region to-list-recovery-points-for-a-gateway-1472143015088

            var client   = new AmazonStorageGatewayClient();
            var response = client.ListVolumeRecoveryPoints(new ListVolumeRecoveryPointsRequest
            {
                GatewayARN = "arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B"
            });

            string gatewayARN = response.GatewayARN;
            List <VolumeRecoveryPointInfo> volumeRecoveryPointInfos = response.VolumeRecoveryPointInfos;

            #endregion
        }
Пример #2
0
        public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems)
        {
            AmazonStorageGatewayConfig config = new AmazonStorageGatewayConfig();

            config.RegionEndpoint = region;
            ConfigureClient(config);
            AmazonStorageGatewayClient client = new AmazonStorageGatewayClient(creds, config);

            ListVolumeRecoveryPointsResponse resp = new ListVolumeRecoveryPointsResponse();
            ListVolumeRecoveryPointsRequest  req  = new ListVolumeRecoveryPointsRequest
            {
            };

            resp = client.ListVolumeRecoveryPoints(req);
            CheckError(resp.HttpStatusCode, "200");

            foreach (var obj in resp.VolumeRecoveryPointInfos)
            {
                AddObject(obj);
            }
        }