public override void ExecuteCmdlet()
        {
            if (ShouldProcess(Name, ResourceProperties.Resources.NewAzureRmIotHubImportDevices))
            {
                var exportDevicesRequest = new PSExportDevicesRequest()
                {
                    ExportBlobContainerUri = this.ExportBlobContainerUri,
                    ExcludeKeys            = this.ExcludeKeys.IsPresent
                };

                JobResponse jobResponse = this.IotHubClient.IotHubResource.ExportDevices(this.ResourceGroupName, this.Name, IotHubUtils.ToExportDevicesRequest(exportDevicesRequest));
                this.WriteObject(IotHubUtils.ToPSIotHubJobResponse(jobResponse), false);
            }
        }
예제 #2
0
 public static ExportDevicesRequest ToExportDevicesRequest(PSExportDevicesRequest psExportDevicesRequest)
 {
     return(ConvertObject <PSExportDevicesRequest, ExportDevicesRequest>(psExportDevicesRequest));
 }