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

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __protectionProfileCustomDetails = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.ProtectionProfileCustomDetails(json);
            { _protectionProfileId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("protectionProfileId"), out var __jsonProtectionProfileId) ? (string)__jsonProtectionProfileId : (string)ProtectionProfileId; }
            AfterFromJson(json);
        }
Beispiel #2
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject into a new instance of <see cref="NewProtectionProfile" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal NewProtectionProfile(Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            __protectionProfileCustomDetails = new Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20210210.ProtectionProfileCustomDetails(json);
            { _policyName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("policyName"), out var __jsonPolicyName) ? (string)__jsonPolicyName : (string)PolicyName; }
            { _recoveryPointHistory = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonNumber>("recoveryPointHistory"), out var __jsonRecoveryPointHistory) ? (int?)__jsonRecoveryPointHistory : RecoveryPointHistory; }
            { _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; }
            { _multiVMSyncStatus = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Migrate.Runtime.Json.JsonString>("multiVmSyncStatus"), out var __jsonMultiVMSyncStatus) ? (string)__jsonMultiVMSyncStatus : (string)MultiVMSyncStatus; }
            AfterFromJson(json);
        }