/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="A2ACrossClusterMigrationPolicyCreationInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal A2ACrossClusterMigrationPolicyCreationInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="InMageRcmFailbackPolicyCreationInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal InMageRcmFailbackPolicyCreationInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); { _crashConsistentFrequencyInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("crashConsistentFrequencyInMinutes"), out var __jsonCrashConsistentFrequencyInMinutes) ? (int?)__jsonCrashConsistentFrequencyInMinutes : CrashConsistentFrequencyInMinute; } { _appConsistentFrequencyInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("appConsistentFrequencyInMinutes"), out var __jsonAppConsistentFrequencyInMinutes) ? (int?)__jsonAppConsistentFrequencyInMinutes : AppConsistentFrequencyInMinute; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="InMageRcmPolicyCreationInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal InMageRcmPolicyCreationInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); { _recoveryPointHistoryInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPointHistoryInMinutes"), out var __jsonRecoveryPointHistoryInMinutes) ? (int?)__jsonRecoveryPointHistoryInMinutes : RecoveryPointHistoryInMinute; } { _crashConsistentFrequencyInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("crashConsistentFrequencyInMinutes"), out var __jsonCrashConsistentFrequencyInMinutes) ? (int?)__jsonCrashConsistentFrequencyInMinutes : CrashConsistentFrequencyInMinute; } { _appConsistentFrequencyInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("appConsistentFrequencyInMinutes"), out var __jsonAppConsistentFrequencyInMinutes) ? (int?)__jsonAppConsistentFrequencyInMinutes : AppConsistentFrequencyInMinute; } { _enableMultiVMSync = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("enableMultiVmSync"), out var __jsonEnableMultiVMSync) ? (string)__jsonEnableMultiVMSync : (string)EnableMultiVMSync; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="InMagePolicyInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal InMagePolicyInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); { _recoveryPointThresholdInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPointThresholdInMinutes"), out var __jsonRecoveryPointThresholdInMinutes) ? (int?)__jsonRecoveryPointThresholdInMinutes : RecoveryPointThresholdInMinute; } { _recoveryPointHistory = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPointHistory"), out var __jsonRecoveryPointHistory) ? (int?)__jsonRecoveryPointHistory : RecoveryPointHistory; } { _appConsistentFrequencyInMinute = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("appConsistentFrequencyInMinutes"), out var __jsonAppConsistentFrequencyInMinutes) ? (int?)__jsonAppConsistentFrequencyInMinutes : AppConsistentFrequencyInMinute; } { _multiVMSyncStatus = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmSyncStatus"), out var __jsonMultiVMSyncStatus) ? (string)__jsonMultiVMSyncStatus : (string)MultiVMSyncStatus; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="HyperVReplicaAzurePolicyInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal HyperVReplicaAzurePolicyInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); { _recoveryPointHistoryDuration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPointHistoryDuration"), out var __jsonRecoveryPointHistoryDuration) ? (int?)__jsonRecoveryPointHistoryDuration : RecoveryPointHistoryDuration; } { _applicationConsistentSnapshotFrequencyInHour = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("applicationConsistentSnapshotFrequencyInHours"), out var __jsonApplicationConsistentSnapshotFrequencyInHours) ? (int?)__jsonApplicationConsistentSnapshotFrequencyInHours : ApplicationConsistentSnapshotFrequencyInHour; } { _replicationInterval = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("replicationInterval"), out var __jsonReplicationInterval) ? (int?)__jsonReplicationInterval : ReplicationInterval; } { _onlineReplicationStartTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("onlineReplicationStartTime"), out var __jsonOnlineReplicationStartTime) ? (string)__jsonOnlineReplicationStartTime : (string)OnlineReplicationStartTime; } { _storageAccount = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray>("storageAccounts"), out var __jsonStorageAccounts) ? If(__jsonStorageAccounts as Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <string[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (string)(__u is Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString __t ? (string)(__t.ToString()) : null))))() : null : StorageAccount; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="HyperVReplicaPolicyInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param> internal HyperVReplicaPolicyInput(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __policyProviderSpecificInput = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.PolicyProviderSpecificInput(json); { _recoveryPoint = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPoints"), out var __jsonRecoveryPoints) ? (int?)__jsonRecoveryPoints : RecoveryPoint; } { _applicationConsistentSnapshotFrequencyInHour = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("applicationConsistentSnapshotFrequencyInHours"), out var __jsonApplicationConsistentSnapshotFrequencyInHours) ? (int?)__jsonApplicationConsistentSnapshotFrequencyInHours : ApplicationConsistentSnapshotFrequencyInHour; } { _compression = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("compression"), out var __jsonCompression) ? (string)__jsonCompression : (string)Compression; } { _initialReplicationMethod = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("initialReplicationMethod"), out var __jsonInitialReplicationMethod) ? (string)__jsonInitialReplicationMethod : (string)InitialReplicationMethod; } { _onlineReplicationStartTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("onlineReplicationStartTime"), out var __jsonOnlineReplicationStartTime) ? (string)__jsonOnlineReplicationStartTime : (string)OnlineReplicationStartTime; } { _offlineReplicationImportPath = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("offlineReplicationImportPath"), out var __jsonOfflineReplicationImportPath) ? (string)__jsonOfflineReplicationImportPath : (string)OfflineReplicationImportPath; } { _offlineReplicationExportPath = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("offlineReplicationExportPath"), out var __jsonOfflineReplicationExportPath) ? (string)__jsonOfflineReplicationExportPath : (string)OfflineReplicationExportPath; } { _replicationPort = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("replicationPort"), out var __jsonReplicationPort) ? (int?)__jsonReplicationPort : ReplicationPort; } { _allowedAuthenticationType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("allowedAuthenticationType"), out var __jsonAllowedAuthenticationType) ? (int?)__jsonAllowedAuthenticationType : AllowedAuthenticationType; } { _replicaDeletion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("replicaDeletion"), out var __jsonReplicaDeletion) ? (string)__jsonReplicaDeletion : (string)ReplicaDeletion; } AfterFromJson(json); }