/// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="InMageReplicationDetails" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal InMageReplicationDetails(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __replicationProviderSpecificSettings = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.ReplicationProviderSpecificSettings(json);
            { _oSDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("osDetails"), out var __jsonOSDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.OSDiskDetails.FromJson(__jsonOSDetails) : OSDetail; }
            { _resyncDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("resyncDetails"), out var __jsonResyncDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InitialReplicationDetails.FromJson(__jsonResyncDetails) : ResyncDetail; }
            { _agentDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("agentDetails"), out var __jsonAgentDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InMageAgentDetails.FromJson(__jsonAgentDetails) : AgentDetail; }
            { _activeSiteType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("activeSiteType"), out var __jsonActiveSiteType) ? (string)__jsonActiveSiteType : (string)ActiveSiteType; }
            { _sourceVMCpuCount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmCpuCount"), out var __jsonSourceVMCpuCount) ? (int?)__jsonSourceVMCpuCount : SourceVMCpuCount; }
            { _sourceVMRamSizeInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmRamSizeInMB"), out var __jsonSourceVMRamSizeInMb) ? (int?)__jsonSourceVMRamSizeInMb : SourceVMRamSizeInMb; }
            { _protectionStage = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("protectionStage"), out var __jsonProtectionStage) ? (string)__jsonProtectionStage : (string)ProtectionStage; }
            { _vMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmId"), out var __jsonVMId) ? (string)__jsonVMId : (string)VMId; }
            { _vMProtectionState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionState"), out var __jsonVMProtectionState) ? (string)__jsonVMProtectionState : (string)VMProtectionState; }
            { _vMProtectionStateDescription = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionStateDescription"), out var __jsonVMProtectionStateDescription) ? (string)__jsonVMProtectionStateDescription : (string)VMProtectionStateDescription; }
            { _retentionWindowStart = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("retentionWindowStart"), out var __jsonRetentionWindowStart) ? global::System.DateTime.TryParse((string)__jsonRetentionWindowStart, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonRetentionWindowStartValue) ? __jsonRetentionWindowStartValue : RetentionWindowStart : RetentionWindowStart; }
            { _retentionWindowEnd = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("retentionWindowEnd"), out var __jsonRetentionWindowEnd) ? global::System.DateTime.TryParse((string)__jsonRetentionWindowEnd, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonRetentionWindowEndValue) ? __jsonRetentionWindowEndValue : RetentionWindowEnd : RetentionWindowEnd; }
            { _compressedDataRateInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("compressedDataRateInMB"), out var __jsonCompressedDataRateInMb) ? (double?)__jsonCompressedDataRateInMb : CompressedDataRateInMb; }
            { _uncompressedDataRateInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("uncompressedDataRateInMB"), out var __jsonUncompressedDataRateInMb) ? (double?)__jsonUncompressedDataRateInMb : UncompressedDataRateInMb; }
            { _rpoInSecond = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("rpoInSeconds"), out var __jsonRpoInSeconds) ? (long?)__jsonRpoInSeconds : RpoInSecond; }
            { _protectedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("protectedDisks"), out var __jsonProtectedDisks) ? If(__jsonProtectedDisks as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IInMageProtectedDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IInMageProtectedDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InMageProtectedDiskDetails.FromJson(__u)))))() : null : ProtectedDisk; }
            { _iPAddress = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("ipAddress"), out var __jsonIPAddress) ? (string)__jsonIPAddress : (string)IPAddress; }
            { _lastHeartbeat = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastHeartbeat"), out var __jsonLastHeartbeat) ? global::System.DateTime.TryParse((string)__jsonLastHeartbeat, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastHeartbeatValue) ? __jsonLastHeartbeatValue : LastHeartbeat : LastHeartbeat; }
            { _processServerId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("processServerId"), out var __jsonProcessServerId) ? (string)__jsonProcessServerId : (string)ProcessServerId; }
            { _masterTargetId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("masterTargetId"), out var __jsonMasterTargetId) ? (string)__jsonMasterTargetId : (string)MasterTargetId; }
            { _consistencyPoint = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("consistencyPoints"), out var __jsonConsistencyPoints) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InMageReplicationDetailsConsistencyPoints.FromJson(__jsonConsistencyPoints) : ConsistencyPoint; }
            { _diskResized = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("diskResized"), out var __jsonDiskResized) ? (string)__jsonDiskResized : (string)DiskResized; }
            { _rebootAfterUpdateStatus = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("rebootAfterUpdateStatus"), out var __jsonRebootAfterUpdateStatus) ? (string)__jsonRebootAfterUpdateStatus : (string)RebootAfterUpdateStatus; }
            { _multiVMGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupId"), out var __jsonMultiVMGroupId) ? (string)__jsonMultiVMGroupId : (string)MultiVMGroupId; }
            { _multiVMGroupName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupName"), out var __jsonMultiVMGroupName) ? (string)__jsonMultiVMGroupName : (string)MultiVMGroupName; }
            { _multiVMSyncStatus = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmSyncStatus"), out var __jsonMultiVMSyncStatus) ? (string)__jsonMultiVMSyncStatus : (string)MultiVMSyncStatus; }
            { _vCenterInfrastructureId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vCenterInfrastructureId"), out var __jsonVCenterInfrastructureId) ? (string)__jsonVCenterInfrastructureId : (string)VCenterInfrastructureId; }
            { _infrastructureVMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("infrastructureVmId"), out var __jsonInfrastructureVMId) ? (string)__jsonInfrastructureVMId : (string)InfrastructureVMId; }
            { _vMNic = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vmNics"), out var __jsonVMNics) ? If(__jsonVMNics as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMNicDetails.FromJson(__p)))))() : null : VMNic; }
            { _discoveryType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("discoveryType"), out var __jsonDiscoveryType) ? (string)__jsonDiscoveryType : (string)DiscoveryType; }
            { _azureStorageAccountId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("azureStorageAccountId"), out var __jsonAzureStorageAccountId) ? (string)__jsonAzureStorageAccountId : (string)AzureStorageAccountId; }
            { _datastore = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("datastores"), out var __jsonDatastores) ? If(__jsonDatastores as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __l) ? new global::System.Func <string[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__l, (__k) => (string)(__k is Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString __j ? (string)(__j.ToString()) : null))))() : null : Datastore; }
            { _validationError = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("validationErrors"), out var __jsonValidationErrors) ? If(__jsonValidationErrors as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __g) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IHealthError[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__g, (__f) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IHealthError)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.HealthError.FromJson(__f)))))() : null : ValidationError; }
            { _lastRpoCalculatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastRpoCalculatedTime"), out var __jsonLastRpoCalculatedTime) ? global::System.DateTime.TryParse((string)__jsonLastRpoCalculatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastRpoCalculatedTimeValue) ? __jsonLastRpoCalculatedTimeValue : LastRpoCalculatedTime : LastRpoCalculatedTime; }
            { _lastUpdateReceivedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastUpdateReceivedTime"), out var __jsonLastUpdateReceivedTime) ? global::System.DateTime.TryParse((string)__jsonLastUpdateReceivedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastUpdateReceivedTimeValue) ? __jsonLastUpdateReceivedTimeValue : LastUpdateReceivedTime : LastUpdateReceivedTime; }
            { _replicaId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("replicaId"), out var __jsonReplicaId) ? (string)__jsonReplicaId : (string)ReplicaId; }
            { _oSVersion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("osVersion"), out var __jsonOSVersion) ? (string)__jsonOSVersion : (string)OSVersion; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="A2AReplicationDetails" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal A2AReplicationDetails(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __replicationProviderSpecificSettings = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.ReplicationProviderSpecificSettings(json);
            { _vMSyncedConfigDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("vmSyncedConfigDetails"), out var __jsonVMSyncedConfigDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.AzureToAzureVMSyncedConfigDetails.FromJson(__jsonVMSyncedConfigDetails) : VMSyncedConfigDetail; }
            { _agentVersion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("agentVersion"), out var __jsonAgentVersion) ? (string)__jsonAgentVersion : (string)AgentVersion; }
            { _fabricObjectId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("fabricObjectId"), out var __jsonFabricObjectId) ? (string)__jsonFabricObjectId : (string)FabricObjectId; }
            { _isReplicationAgentUpdateRequired = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonBoolean>("isReplicationAgentUpdateRequired"), out var __jsonIsReplicationAgentUpdateRequired) ? (bool?)__jsonIsReplicationAgentUpdateRequired : IsReplicationAgentUpdateRequired; }
            { _lastHeartbeat = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastHeartbeat"), out var __jsonLastHeartbeat) ? global::System.DateTime.TryParse((string)__jsonLastHeartbeat, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastHeartbeatValue) ? __jsonLastHeartbeatValue : LastHeartbeat : LastHeartbeat; }
            { _lastRpoCalculatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastRpoCalculatedTime"), out var __jsonLastRpoCalculatedTime) ? global::System.DateTime.TryParse((string)__jsonLastRpoCalculatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastRpoCalculatedTimeValue) ? __jsonLastRpoCalculatedTimeValue : LastRpoCalculatedTime : LastRpoCalculatedTime; }
            { _lifecycleId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lifecycleId"), out var __jsonLifecycleId) ? (string)__jsonLifecycleId : (string)LifecycleId; }
            { _managementId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("managementId"), out var __jsonManagementId) ? (string)__jsonManagementId : (string)ManagementId; }
            { _monitoringJobType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("monitoringJobType"), out var __jsonMonitoringJobType) ? (string)__jsonMonitoringJobType : (string)MonitoringJobType; }
            { _monitoringPercentageCompletion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("monitoringPercentageCompletion"), out var __jsonMonitoringPercentageCompletion) ? (int?)__jsonMonitoringPercentageCompletion : MonitoringPercentageCompletion; }
            { _multiVMGroupCreateOption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupCreateOption"), out var __jsonMultiVMGroupCreateOption) ? (string)__jsonMultiVMGroupCreateOption : (string)MultiVMGroupCreateOption; }
            { _multiVMGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupId"), out var __jsonMultiVMGroupId) ? (string)__jsonMultiVMGroupId : (string)MultiVMGroupId; }
            { _multiVMGroupName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupName"), out var __jsonMultiVMGroupName) ? (string)__jsonMultiVMGroupName : (string)MultiVMGroupName; }
            { _oSType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("osType"), out var __jsonOSType) ? (string)__jsonOSType : (string)OSType; }
            { _primaryFabricLocation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("primaryFabricLocation"), out var __jsonPrimaryFabricLocation) ? (string)__jsonPrimaryFabricLocation : (string)PrimaryFabricLocation; }
            { _protectedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("protectedDisks"), out var __jsonProtectedDisks) ? If(__jsonProtectedDisks as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IA2AProtectedDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IA2AProtectedDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.A2AProtectedDiskDetails.FromJson(__u)))))() : null : ProtectedDisk; }
            { _protectedManagedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("protectedManagedDisks"), out var __jsonProtectedManagedDisks) ? If(__jsonProtectedManagedDisks as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IA2AProtectedManagedDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IA2AProtectedManagedDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.A2AProtectedManagedDiskDetails.FromJson(__p)))))() : null : ProtectedManagedDisk; }
            { _recoveryAvailabilitySet = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAvailabilitySet"), out var __jsonRecoveryAvailabilitySet) ? (string)__jsonRecoveryAvailabilitySet : (string)RecoveryAvailabilitySet; }
            { _recoveryAzureResourceGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureResourceGroupId"), out var __jsonRecoveryAzureResourceGroupId) ? (string)__jsonRecoveryAzureResourceGroupId : (string)RecoveryAzureResourceGroupId; }
            { _recoveryAzureVMName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVMName"), out var __jsonRecoveryAzureVMName) ? (string)__jsonRecoveryAzureVMName : (string)RecoveryAzureVMName; }
            { _recoveryAzureVMSize = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVMSize"), out var __jsonRecoveryAzureVMSize) ? (string)__jsonRecoveryAzureVMSize : (string)RecoveryAzureVMSize; }
            { _recoveryBootDiagStorageAccountId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryBootDiagStorageAccountId"), out var __jsonRecoveryBootDiagStorageAccountId) ? (string)__jsonRecoveryBootDiagStorageAccountId : (string)RecoveryBootDiagStorageAccountId; }
            { _recoveryCloudService = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryCloudService"), out var __jsonRecoveryCloudService) ? (string)__jsonRecoveryCloudService : (string)RecoveryCloudService; }
            { _recoveryFabricLocation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryFabricLocation"), out var __jsonRecoveryFabricLocation) ? (string)__jsonRecoveryFabricLocation : (string)RecoveryFabricLocation; }
            { _recoveryFabricObjectId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryFabricObjectId"), out var __jsonRecoveryFabricObjectId) ? (string)__jsonRecoveryFabricObjectId : (string)RecoveryFabricObjectId; }
            { _rpoInSecond = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("rpoInSeconds"), out var __jsonRpoInSeconds) ? (long?)__jsonRpoInSeconds : RpoInSecond; }
            { _selectedRecoveryAzureNetworkId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("selectedRecoveryAzureNetworkId"), out var __jsonSelectedRecoveryAzureNetworkId) ? (string)__jsonSelectedRecoveryAzureNetworkId : (string)SelectedRecoveryAzureNetworkId; }
            { _testFailoverRecoveryFabricObjectId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("testFailoverRecoveryFabricObjectId"), out var __jsonTestFailoverRecoveryFabricObjectId) ? (string)__jsonTestFailoverRecoveryFabricObjectId : (string)TestFailoverRecoveryFabricObjectId; }
            { _vMNic = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vmNics"), out var __jsonVMNics) ? If(__jsonVMNics as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __l) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__l, (__k) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMNicDetails.FromJson(__k)))))() : null : VMNic; }
            { _vMProtectionState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionState"), out var __jsonVMProtectionState) ? (string)__jsonVMProtectionState : (string)VMProtectionState; }
            { _vMProtectionStateDescription = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionStateDescription"), out var __jsonVMProtectionStateDescription) ? (string)__jsonVMProtectionStateDescription : (string)VMProtectionStateDescription; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="HyperVReplicaBaseReplicationDetails" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal HyperVReplicaBaseReplicationDetails(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __replicationProviderSpecificSettings = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.ReplicationProviderSpecificSettings(json);
            { _initialReplicationDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("initialReplicationDetails"), out var __jsonInitialReplicationDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InitialReplicationDetails.FromJson(__jsonInitialReplicationDetails) : InitialReplicationDetail; }
            { _lastReplicatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastReplicatedTime"), out var __jsonLastReplicatedTime) ? global::System.DateTime.TryParse((string)__jsonLastReplicatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastReplicatedTimeValue) ? __jsonLastReplicatedTimeValue : LastReplicatedTime : LastReplicatedTime; }
            { _vMDiskDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vMDiskDetails"), out var __jsonVMDiskDetails) ? If(__jsonVMDiskDetails as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.DiskDetails.FromJson(__u)))))() : null : VMDiskDetail; }
            { _vMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmId"), out var __jsonVMId) ? (string)__jsonVMId : (string)VMId; }
            { _vMNic = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vmNics"), out var __jsonVMNics) ? If(__jsonVMNics as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMNicDetails.FromJson(__p)))))() : null : VMNic; }
            { _vMProtectionState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionState"), out var __jsonVMProtectionState) ? (string)__jsonVMProtectionState : (string)VMProtectionState; }
            { _vMProtectionStateDescription = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionStateDescription"), out var __jsonVMProtectionStateDescription) ? (string)__jsonVMProtectionStateDescription : (string)VMProtectionStateDescription; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="HyperVReplicaAzureReplicationDetails" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal HyperVReplicaAzureReplicationDetails(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __replicationProviderSpecificSettings = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.ReplicationProviderSpecificSettings(json);
            { _initialReplicationDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("initialReplicationDetails"), out var __jsonInitialReplicationDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InitialReplicationDetails.FromJson(__jsonInitialReplicationDetails) : InitialReplicationDetail; }
            { _oSDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject>("oSDetails"), out var __jsonOSDetails) ? Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.OSDetails.FromJson(__jsonOSDetails) : OSDetail; }
            { _azureVMDiskDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("azureVmDiskDetails"), out var __jsonAzureVMDiskDetails) ? If(__jsonAzureVMDiskDetails as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IAzureVMDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IAzureVMDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.AzureVMDiskDetails.FromJson(__u)))))() : null : AzureVMDiskDetail; }
            { _recoveryAzureVMName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVmName"), out var __jsonRecoveryAzureVMName) ? (string)__jsonRecoveryAzureVMName : (string)RecoveryAzureVMName; }
            { _recoveryAzureVMSize = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVMSize"), out var __jsonRecoveryAzureVMSize) ? (string)__jsonRecoveryAzureVMSize : (string)RecoveryAzureVMSize; }
            { _recoveryAzureStorageAccount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureStorageAccount"), out var __jsonRecoveryAzureStorageAccount) ? (string)__jsonRecoveryAzureStorageAccount : (string)RecoveryAzureStorageAccount; }
            { _recoveryAzureLogStorageAccountId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureLogStorageAccountId"), out var __jsonRecoveryAzureLogStorageAccountId) ? (string)__jsonRecoveryAzureLogStorageAccountId : (string)RecoveryAzureLogStorageAccountId; }
            { _lastReplicatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastReplicatedTime"), out var __jsonLastReplicatedTime) ? global::System.DateTime.TryParse((string)__jsonLastReplicatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastReplicatedTimeValue) ? __jsonLastReplicatedTimeValue : LastReplicatedTime : LastReplicatedTime; }
            { _rpoInSecond = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("rpoInSeconds"), out var __jsonRpoInSeconds) ? (long?)__jsonRpoInSeconds : RpoInSecond; }
            { _lastRpoCalculatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastRpoCalculatedTime"), out var __jsonLastRpoCalculatedTime) ? global::System.DateTime.TryParse((string)__jsonLastRpoCalculatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastRpoCalculatedTimeValue) ? __jsonLastRpoCalculatedTimeValue : LastRpoCalculatedTime : LastRpoCalculatedTime; }
            { _vMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmId"), out var __jsonVMId) ? (string)__jsonVMId : (string)VMId; }
            { _vMProtectionState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionState"), out var __jsonVMProtectionState) ? (string)__jsonVMProtectionState : (string)VMProtectionState; }
            { _vMProtectionStateDescription = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionStateDescription"), out var __jsonVMProtectionStateDescription) ? (string)__jsonVMProtectionStateDescription : (string)VMProtectionStateDescription; }
            { _vMNic = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vmNics"), out var __jsonVMNics) ? If(__jsonVMNics as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMNicDetails.FromJson(__p)))))() : null : VMNic; }
            { _selectedRecoveryAzureNetworkId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("selectedRecoveryAzureNetworkId"), out var __jsonSelectedRecoveryAzureNetworkId) ? (string)__jsonSelectedRecoveryAzureNetworkId : (string)SelectedRecoveryAzureNetworkId; }
            { _selectedSourceNicId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("selectedSourceNicId"), out var __jsonSelectedSourceNicId) ? (string)__jsonSelectedSourceNicId : (string)SelectedSourceNicId; }
            { _encryption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("encryption"), out var __jsonEncryption) ? (string)__jsonEncryption : (string)Encryption; }
            { _sourceVMRamSizeInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmRamSizeInMB"), out var __jsonSourceVMRamSizeInMb) ? (int?)__jsonSourceVMRamSizeInMb : SourceVMRamSizeInMb; }
            { _sourceVMCpuCount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmCpuCount"), out var __jsonSourceVMCpuCount) ? (int?)__jsonSourceVMCpuCount : SourceVMCpuCount; }
            { _enableRdpOnTargetOption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("enableRdpOnTargetOption"), out var __jsonEnableRdpOnTargetOption) ? (string)__jsonEnableRdpOnTargetOption : (string)EnableRdpOnTargetOption; }
            { _recoveryAzureResourceGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureResourceGroupId"), out var __jsonRecoveryAzureResourceGroupId) ? (string)__jsonRecoveryAzureResourceGroupId : (string)RecoveryAzureResourceGroupId; }
            { _recoveryAvailabilitySetId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAvailabilitySetId"), out var __jsonRecoveryAvailabilitySetId) ? (string)__jsonRecoveryAvailabilitySetId : (string)RecoveryAvailabilitySetId; }
            { _useManagedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("useManagedDisks"), out var __jsonUseManagedDisks) ? (string)__jsonUseManagedDisks : (string)UseManagedDisk; }
            { _licenseType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("licenseType"), out var __jsonLicenseType) ? (string)__jsonLicenseType : (string)LicenseType; }
            AfterFromJson(json);
        }
Esempio n. 5
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="InMageAzureV2ReplicationDetails" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal InMageAzureV2ReplicationDetails(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __replicationProviderSpecificSettings = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.ReplicationProviderSpecificSettings(json);
            { _infrastructureVMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("infrastructureVmId"), out var __jsonInfrastructureVMId) ? (string)__jsonInfrastructureVMId : (string)InfrastructureVMId; }
            { _vCenterInfrastructureId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vCenterInfrastructureId"), out var __jsonVCenterInfrastructureId) ? (string)__jsonVCenterInfrastructureId : (string)VCenterInfrastructureId; }
            { _protectionStage = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("protectionStage"), out var __jsonProtectionStage) ? (string)__jsonProtectionStage : (string)ProtectionStage; }
            { _vMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmId"), out var __jsonVMId) ? (string)__jsonVMId : (string)VMId; }
            { _vMProtectionState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionState"), out var __jsonVMProtectionState) ? (string)__jsonVMProtectionState : (string)VMProtectionState; }
            { _vMProtectionStateDescription = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vmProtectionStateDescription"), out var __jsonVMProtectionStateDescription) ? (string)__jsonVMProtectionStateDescription : (string)VMProtectionStateDescription; }
            { _resyncProgressPercentage = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("resyncProgressPercentage"), out var __jsonResyncProgressPercentage) ? (int?)__jsonResyncProgressPercentage : ResyncProgressPercentage; }
            { _rpoInSecond = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("rpoInSeconds"), out var __jsonRpoInSeconds) ? (long?)__jsonRpoInSeconds : RpoInSecond; }
            { _compressedDataRateInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("compressedDataRateInMB"), out var __jsonCompressedDataRateInMb) ? (double?)__jsonCompressedDataRateInMb : CompressedDataRateInMb; }
            { _uncompressedDataRateInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("uncompressedDataRateInMB"), out var __jsonUncompressedDataRateInMb) ? (double?)__jsonUncompressedDataRateInMb : UncompressedDataRateInMb; }
            { _iPAddress = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("ipAddress"), out var __jsonIPAddress) ? (string)__jsonIPAddress : (string)IPAddress; }
            { _agentVersion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("agentVersion"), out var __jsonAgentVersion) ? (string)__jsonAgentVersion : (string)AgentVersion; }
            { _agentExpiryDate = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("agentExpiryDate"), out var __jsonAgentExpiryDate) ? global::System.DateTime.TryParse((string)__jsonAgentExpiryDate, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonAgentExpiryDateValue) ? __jsonAgentExpiryDateValue : AgentExpiryDate : AgentExpiryDate; }
            { _isAgentUpdateRequired = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("isAgentUpdateRequired"), out var __jsonIsAgentUpdateRequired) ? (string)__jsonIsAgentUpdateRequired : (string)IsAgentUpdateRequired; }
            { _isRebootAfterUpdateRequired = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("isRebootAfterUpdateRequired"), out var __jsonIsRebootAfterUpdateRequired) ? (string)__jsonIsRebootAfterUpdateRequired : (string)IsRebootAfterUpdateRequired; }
            { _lastHeartbeat = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastHeartbeat"), out var __jsonLastHeartbeat) ? global::System.DateTime.TryParse((string)__jsonLastHeartbeat, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastHeartbeatValue) ? __jsonLastHeartbeatValue : LastHeartbeat : LastHeartbeat; }
            { _processServerId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("processServerId"), out var __jsonProcessServerId) ? (string)__jsonProcessServerId : (string)ProcessServerId; }
            { _multiVMGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupId"), out var __jsonMultiVMGroupId) ? (string)__jsonMultiVMGroupId : (string)MultiVMGroupId; }
            { _multiVMGroupName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmGroupName"), out var __jsonMultiVMGroupName) ? (string)__jsonMultiVMGroupName : (string)MultiVMGroupName; }
            { _multiVMSyncStatus = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmSyncStatus"), out var __jsonMultiVMSyncStatus) ? (string)__jsonMultiVMSyncStatus : (string)MultiVMSyncStatus; }
            { _protectedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("protectedDisks"), out var __jsonProtectedDisks) ? If(__jsonProtectedDisks as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IInMageAzureV2ProtectedDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IInMageAzureV2ProtectedDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.InMageAzureV2ProtectedDiskDetails.FromJson(__u)))))() : null : ProtectedDisk; }
            { _diskResized = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("diskResized"), out var __jsonDiskResized) ? (string)__jsonDiskResized : (string)DiskResized; }
            { _masterTargetId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("masterTargetId"), out var __jsonMasterTargetId) ? (string)__jsonMasterTargetId : (string)MasterTargetId; }
            { _sourceVMCpuCount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmCpuCount"), out var __jsonSourceVMCpuCount) ? (int?)__jsonSourceVMCpuCount : SourceVMCpuCount; }
            { _sourceVMRamSizeInMb = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("sourceVmRamSizeInMB"), out var __jsonSourceVMRamSizeInMb) ? (int?)__jsonSourceVMRamSizeInMb : SourceVMRamSizeInMb; }
            { _oSType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("osType"), out var __jsonOSType) ? (string)__jsonOSType : (string)OSType; }
            { _vhdName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("vhdName"), out var __jsonVhdName) ? (string)__jsonVhdName : (string)VhdName; }
            { _oSDiskId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("osDiskId"), out var __jsonOSDiskId) ? (string)__jsonOSDiskId : (string)OSDiskId; }
            { _azureVMDiskDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("azureVMDiskDetails"), out var __jsonAzureVMDiskDetails) ? If(__jsonAzureVMDiskDetails as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IAzureVMDiskDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IAzureVMDiskDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.AzureVMDiskDetails.FromJson(__p)))))() : null : AzureVMDiskDetail; }
            { _recoveryAzureVMName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVMName"), out var __jsonRecoveryAzureVMName) ? (string)__jsonRecoveryAzureVMName : (string)RecoveryAzureVMName; }
            { _recoveryAzureVMSize = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureVMSize"), out var __jsonRecoveryAzureVMSize) ? (string)__jsonRecoveryAzureVMSize : (string)RecoveryAzureVMSize; }
            { _recoveryAzureStorageAccount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureStorageAccount"), out var __jsonRecoveryAzureStorageAccount) ? (string)__jsonRecoveryAzureStorageAccount : (string)RecoveryAzureStorageAccount; }
            { _recoveryAzureLogStorageAccountId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureLogStorageAccountId"), out var __jsonRecoveryAzureLogStorageAccountId) ? (string)__jsonRecoveryAzureLogStorageAccountId : (string)RecoveryAzureLogStorageAccountId; }
            { _vMNic = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("vmNics"), out var __jsonVMNics) ? If(__jsonVMNics as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __l) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__l, (__k) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IVMNicDetails)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMNicDetails.FromJson(__k)))))() : null : VMNic; }
            { _selectedRecoveryAzureNetworkId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("selectedRecoveryAzureNetworkId"), out var __jsonSelectedRecoveryAzureNetworkId) ? (string)__jsonSelectedRecoveryAzureNetworkId : (string)SelectedRecoveryAzureNetworkId; }
            { _selectedSourceNicId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("selectedSourceNicId"), out var __jsonSelectedSourceNicId) ? (string)__jsonSelectedSourceNicId : (string)SelectedSourceNicId; }
            { _discoveryType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("discoveryType"), out var __jsonDiscoveryType) ? (string)__jsonDiscoveryType : (string)DiscoveryType; }
            { _enableRdpOnTargetOption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("enableRdpOnTargetOption"), out var __jsonEnableRdpOnTargetOption) ? (string)__jsonEnableRdpOnTargetOption : (string)EnableRdpOnTargetOption; }
            { _datastore = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("datastores"), out var __jsonDatastores) ? If(__jsonDatastores as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __g) ? new global::System.Func <string[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__g, (__f) => (string)(__f is Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString __e ? (string)(__e.ToString()) : null))))() : null : Datastore; }
            { _targetVMId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("targetVmId"), out var __jsonTargetVMId) ? (string)__jsonTargetVMId : (string)TargetVMId; }
            { _recoveryAzureResourceGroupId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAzureResourceGroupId"), out var __jsonRecoveryAzureResourceGroupId) ? (string)__jsonRecoveryAzureResourceGroupId : (string)RecoveryAzureResourceGroupId; }
            { _recoveryAvailabilitySetId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("recoveryAvailabilitySetId"), out var __jsonRecoveryAvailabilitySetId) ? (string)__jsonRecoveryAvailabilitySetId : (string)RecoveryAvailabilitySetId; }
            { _useManagedDisk = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("useManagedDisks"), out var __jsonUseManagedDisks) ? (string)__jsonUseManagedDisks : (string)UseManagedDisk; }
            { _licenseType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("licenseType"), out var __jsonLicenseType) ? (string)__jsonLicenseType : (string)LicenseType; }
            { _validationError = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("validationErrors"), out var __jsonValidationErrors) ? If(__jsonValidationErrors as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __b) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IHealthError[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__b, (__a) => (Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.IHealthError)(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.HealthError.FromJson(__a)))))() : null : ValidationError; }
            { _lastRpoCalculatedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastRpoCalculatedTime"), out var __jsonLastRpoCalculatedTime) ? global::System.DateTime.TryParse((string)__jsonLastRpoCalculatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastRpoCalculatedTimeValue) ? __jsonLastRpoCalculatedTimeValue : LastRpoCalculatedTime : LastRpoCalculatedTime; }
            { _lastUpdateReceivedTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("lastUpdateReceivedTime"), out var __jsonLastUpdateReceivedTime) ? global::System.DateTime.TryParse((string)__jsonLastUpdateReceivedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastUpdateReceivedTimeValue) ? __jsonLastUpdateReceivedTimeValue : LastUpdateReceivedTime : LastUpdateReceivedTime; }
            { _replicaId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("replicaId"), out var __jsonReplicaId) ? (string)__jsonReplicaId : (string)ReplicaId; }
            { _oSVersion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("osVersion"), out var __jsonOSVersion) ? (string)__jsonOSVersion : (string)OSVersion; }
            AfterFromJson(json);
        }