Esempio n. 1
0
        private List <RecoveryPointBase> GetMoveRecommendedRecoveryPoints(Dictionary <Enum, object> ProviderData)
        {
            string   vaultName         = (string)ProviderData[VaultParams.VaultName];
            string   resourceGroupName = (string)ProviderData[VaultParams.ResourceGroupName];
            ItemBase item = ProviderData[RecoveryPointParams.Item] as ItemBase;

            Dictionary <UriEnums, string> uriDict = HelperUtils.ParseUri(item.Id);
            string containerUri      = HelperUtils.GetContainerUri(uriDict, item.Id);
            string protectedItemName = HelperUtils.GetProtectedItemUri(uriDict, item.Id);

            ServiceClientModel.ListRecoveryPointsRecommendedForMoveRequest moveRequest = new ServiceClientModel.ListRecoveryPointsRecommendedForMoveRequest();

            List <ServiceClientModel.RecoveryPointResource> rpListResponse;

            rpListResponse = ServiceClientAdapter.GetMoveRecommendedRecoveryPoints(
                containerUri,
                protectedItemName,
                moveRequest,
                vaultName: vaultName,
                resourceGroupName: resourceGroupName);

            return(RecoveryPointConversions.GetPSAzureRecoveryPoints(rpListResponse, item));
        }