/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="StorageSetting" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal StorageSetting(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; } { _dataStoreType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("dataStoreType"), out var __jsonDataStoreType) ? (string)__jsonDataStoreType : (string)DataStoreType; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="BasePolicyRule" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal BasePolicyRule(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } { _objectType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("objectType"), out var __jsonObjectType) ? (string)__jsonObjectType : (string)ObjectType; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="RestoreJobRecoveryPointDetails" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal RestoreJobRecoveryPointDetails(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _recoveryPointId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("recoveryPointID"), out var __jsonRecoveryPointId) ? (string)__jsonRecoveryPointId : (string)RecoveryPointId; } { _recoveryPointTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("recoveryPointTime"), out var __jsonRecoveryPointTime) ? global::System.DateTime.TryParse((string)__jsonRecoveryPointTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonRecoveryPointTimeValue) ? __jsonRecoveryPointTimeValue : RecoveryPointTime : RecoveryPointTime; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="PatchResourceRequestInput" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal PatchResourceRequestInput(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _identity = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("identity"), out var __jsonIdentity) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.DppIdentityDetails.FromJson(__jsonIdentity) : Identity; } { _tag = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("tags"), out var __jsonTags) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.PatchResourceRequestInputTags.FromJson(__jsonTags) : Tag; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="BaseBackupPolicy" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal BaseBackupPolicy(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _datasourceType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("datasourceTypes"), out var __jsonDatasourceTypes) ? If(__jsonDatasourceTypes as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.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.DataProtectionBackup.Runtime.Json.JsonString __t ? (string)(__t.ToString()) : null))))() : null : DatasourceType; } { _objectType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("objectType"), out var __jsonObjectType) ? (string)__jsonObjectType : (string)ObjectType; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="Day" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal Day(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _date = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonNumber>("date"), out var __jsonDate) ? (int?)__jsonDate : Date; } { _isLast = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonBoolean>("isLast"), out var __jsonIsLast) ? (bool?)__jsonIsLast : IsLast; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ProtectionStatusDetails" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ProtectionStatusDetails(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _errorDetail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("errorDetails"), out var __jsonErrorDetails) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.UserFacingError.FromJson(__jsonErrorDetails) : ErrorDetail; } { _status = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("status"), out var __jsonStatus) ? (string)__jsonStatus : (string)Status; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="TargetCopySetting" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal TargetCopySetting(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _copyAfter = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("copyAfter"), out var __jsonCopyAfter) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.CopyOption.FromJson(__jsonCopyAfter) : CopyAfter; } { _dataStore = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("dataStore"), out var __jsonDataStore) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.DataStoreInfoBase.FromJson(__jsonDataStore) : DataStore; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="PolicyInfo" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal PolicyInfo(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _policyId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("policyId"), out var __jsonPolicyId) ? (string)__jsonPolicyId : (string)PolicyId; } { _policyVersion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("policyVersion"), out var __jsonPolicyVersion) ? (string)__jsonPolicyVersion : (string)PolicyVersion; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="BackupVault" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal BackupVault(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _provisioningState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("provisioningState"), out var __jsonProvisioningState) ? (string)__jsonProvisioningState : (string)ProvisioningState; } { _storageSetting = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("storageSettings"), out var __jsonStorageSettings) ? If(__jsonStorageSettings as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.IStorageSetting[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.IStorageSetting)(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.StorageSetting.FromJson(__u)))))() : null : StorageSetting; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ErrorAdditionalInfo1" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ErrorAdditionalInfo1(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _info = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("info"), out var __jsonInfo) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ErrorAdditionalInfo2.FromJson(__jsonInfo) : Info; } { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="AdHocBackupRuleOptions" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal AdHocBackupRuleOptions(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _triggerOption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("triggerOption"), out var __jsonTriggerOption) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.AdhocBackupTriggerOption.FromJson(__jsonTriggerOption) : TriggerOption; } { _ruleName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("ruleName"), out var __jsonRuleName) ? (string)__jsonRuleName : (string)RuleName; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="CheckNameAvailabilityRequest" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal CheckNameAvailabilityRequest(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ClientDiscoveryResponse" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ClientDiscoveryResponse(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _nextLink = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("nextLink"), out var __jsonNextLink) ? (string)__jsonNextLink : (string)NextLink; } { _value = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("value"), out var __jsonValue) ? If(__jsonValue as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.IClientDiscoveryValueForSingleApi[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.IClientDiscoveryValueForSingleApi)(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ClientDiscoveryValueForSingleApi.FromJson(__u)))))() : null : Value; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="DeleteOption" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal DeleteOption(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _duration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("duration"), out var __jsonDuration) ? (string)__jsonDuration : (string)Duration; } { _objectType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("objectType"), out var __jsonObjectType) ? (string)__jsonObjectType : (string)ObjectType; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="RetentionTag" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal RetentionTag(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _eTag = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("eTag"), out var __jsonETag) ? (string)__jsonETag : (string)ETag; } { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; } { _tagName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("tagName"), out var __jsonTagName) ? (string)__jsonTagName : (string)TagName; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="TargetDetails" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal TargetDetails(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _filePrefix = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("filePrefix"), out var __jsonFilePrefix) ? (string)__jsonFilePrefix : (string)FilePrefix; } { _restoreTargetLocationType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("restoreTargetLocationType"), out var __jsonRestoreTargetLocationType) ? (string)__jsonRestoreTargetLocationType : (string)RestoreTargetLocationType; } { _url = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("url"), out var __jsonUrl) ? (string)__jsonUrl : (string)Url; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="CheckNameAvailabilityResult" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal CheckNameAvailabilityResult(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _message = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("message"), out var __jsonMessage) ? (string)__jsonMessage : (string)Message; } { _nameAvailable = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonBoolean>("nameAvailable"), out var __jsonNameAvailable) ? (bool?)__jsonNameAvailable : NameAvailable; } { _reason = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("reason"), out var __jsonReason) ? (string)__jsonReason : (string)Reason; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ScheduleBasedTriggerContext" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ScheduleBasedTriggerContext(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __triggerContext = new Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.TriggerContext(json); { _schedule = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("schedule"), out var __jsonSchedule) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.BackupSchedule.FromJson(__jsonSchedule) : Schedule; } { _taggingCriterion = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("taggingCriteria"), out var __jsonTaggingCriteria) ? If(__jsonTaggingCriteria as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ITaggingCriteria[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ITaggingCriteria)(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.TaggingCriteria.FromJson(__u)))))() : null : TaggingCriterion; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="InnerError" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal InnerError(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _additionalInfo = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("additionalInfo"), out var __jsonAdditionalInfo) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.InnerErrorAdditionalInfo.FromJson(__jsonAdditionalInfo) : AdditionalInfo; } { _code = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("code"), out var __jsonCode) ? (string)__jsonCode : (string)Code; } { _embeddedInnerError = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("embeddedInnerError"), out var __jsonEmbeddedInnerError) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.InnerError.FromJson(__jsonEmbeddedInnerError) : EmbeddedInnerError; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="AzureRetentionRule" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal AzureRetentionRule(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __basePolicyRule = new Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.BasePolicyRule(json); { _isDefault = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonBoolean>("isDefault"), out var __jsonIsDefault) ? (bool?)__jsonIsDefault : IsDefault; } { _lifecycle = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("lifecycles"), out var __jsonLifecycles) ? If(__jsonLifecycles as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ISourceLifeCycle[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ISourceLifeCycle)(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.SourceLifeCycle.FromJson(__u)))))() : null : Lifecycle; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="DppResource" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal DppResource(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; } { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="RestoreTargetInfo" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal RestoreTargetInfo(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __restoreTargetInfoBase = new Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.RestoreTargetInfoBase(json); { _datasourceInfo = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("datasourceInfo"), out var __jsonDatasourceInfo) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.Datasource.FromJson(__jsonDatasourceInfo) : DatasourceInfo; } { _datasourceSetInfo = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("datasourceSetInfo"), out var __jsonDatasourceSetInfo) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.DatasourceSet.FromJson(__jsonDatasourceSetInfo) : DatasourceSetInfo; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ResourceOperationGateKeeper" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ResourceOperationGateKeeper(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _lastLockUpdateTime = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("lastLockUpdateTime"), out var __jsonLastLockUpdateTime) ? global::System.DateTime.TryParse((string)__jsonLastLockUpdateTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonLastLockUpdateTimeValue) ? __jsonLastLockUpdateTimeValue : LastLockUpdateTime : LastLockUpdateTime; } { _provisioningState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("provisioningState"), out var __jsonProvisioningState) ? (string)__jsonProvisioningState : (string)ProvisioningState; } { _operation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("operations"), out var __jsonOperations) ? If(__jsonOperations as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.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.DataProtectionBackup.Runtime.Json.JsonString __t ? (string)(__t.ToString()) : null))))() : null : Operation; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="AzureBackupRehydrationRequest" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal AzureBackupRehydrationRequest(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _recoveryPointId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("recoveryPointId"), out var __jsonRecoveryPointId) ? (string)__jsonRecoveryPointId : (string)RecoveryPointId; } { _rehydrationPriority = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("rehydrationPriority"), out var __jsonRehydrationPriority) ? (string)__jsonRehydrationPriority : (string)RehydrationPriority; } { _rehydrationRetentionDuration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("rehydrationRetentionDuration"), out var __jsonRehydrationRetentionDuration) ? (string)__jsonRehydrationRetentionDuration : (string)RehydrationRetentionDuration; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="AzureBackupRestoreRequest" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal AzureBackupRestoreRequest(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _restoreTargetInfo = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("restoreTargetInfo"), out var __jsonRestoreTargetInfo) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.RestoreTargetInfoBase.FromJson(__jsonRestoreTargetInfo) : RestoreTargetInfo; } { _objectType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("objectType"), out var __jsonObjectType) ? (string)__jsonObjectType : (string)ObjectType; } { _sourceDataStoreType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("sourceDataStoreType"), out var __jsonSourceDataStoreType) ? (string)__jsonSourceDataStoreType : (string)SourceDataStoreType; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="SourceLifeCycle" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal SourceLifeCycle(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _deleteAfter = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("deleteAfter"), out var __jsonDeleteAfter) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.DeleteOption.FromJson(__jsonDeleteAfter) : DeleteAfter; } { _sourceDataStore = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject>("sourceDataStore"), out var __jsonSourceDataStore) ? Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.DataStoreInfoBase.FromJson(__jsonSourceDataStore) : SourceDataStore; } { _targetDataStoreCopySetting = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray>("targetDataStoreCopySettings"), out var __jsonTargetDataStoreCopySettings) ? If(__jsonTargetDataStoreCopySettings as Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ITargetCopySetting[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.ITargetCopySetting)(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.TargetCopySetting.FromJson(__u)))))() : null : TargetDataStoreCopySetting; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="ClientDiscoveryForLogSpecification" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal ClientDiscoveryForLogSpecification(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } { _blobDuration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("blobDuration"), out var __jsonBlobDuration) ? (string)__jsonBlobDuration : (string)BlobDuration; } { _displayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("displayName"), out var __jsonDisplayName) ? (string)__jsonDisplayName : (string)DisplayName; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="AzureBackupRestoreWithRehydrationRequest" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal AzureBackupRestoreWithRehydrationRequest(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } __azureBackupRecoveryPointBasedRestoreRequest = new Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Models.Api202001Alpha.AzureBackupRecoveryPointBasedRestoreRequest(json); { _rehydrationPriority = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("rehydrationPriority"), out var __jsonRehydrationPriority) ? (string)__jsonRehydrationPriority : (string)RehydrationPriority; } { _rehydrationRetentionDuration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("rehydrationRetentionDuration"), out var __jsonRehydrationRetentionDuration) ? (string)__jsonRehydrationRetentionDuration : (string)RehydrationRetentionDuration; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject into a new instance of <see cref="RestoreTargetInfoBase" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject instance to deserialize from.</param> internal RestoreTargetInfoBase(Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _objectType = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("objectType"), out var __jsonObjectType) ? (string)__jsonObjectType : (string)ObjectType; } { _recoveryOption = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("recoveryOption"), out var __jsonRecoveryOption) ? (string)__jsonRecoveryOption : (string)RecoveryOption; } { _restoreLocation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.DataProtectionBackup.Runtime.Json.JsonString>("restoreLocation"), out var __jsonRestoreLocation) ? (string)__jsonRestoreLocation : (string)RestoreLocation; } AfterFromJson(json); }