/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="Operation" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal Operation(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _display = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject>("display"), out var __jsonDisplay) ? Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.OperationDisplay.FromJson(__jsonDisplay) : Display; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="MarketplaceRegistrationDefinitionList" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal MarketplaceRegistrationDefinitionList(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _value = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("value"), out var __jsonValue) ? If(__jsonValue as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IMarketplaceRegistrationDefinition[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IMarketplaceRegistrationDefinition)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.MarketplaceRegistrationDefinition.FromJson(__u)))))() : null : Value; } { _nextLink = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("nextLink"), out var __jsonNextLink) ? (string)__jsonNextLink : (string)NextLink; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="EligibleApprover" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal EligibleApprover(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _principalId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalId"), out var __jsonPrincipalId) ? (string)__jsonPrincipalId : (string)PrincipalId; } { _principalIdDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalIdDisplayName"), out var __jsonPrincipalIdDisplayName) ? (string)__jsonPrincipalIdDisplayName : (string)PrincipalIdDisplayName; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="RegistrationAssignmentProperties" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal RegistrationAssignmentProperties(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _registrationDefinition = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject>("registrationDefinition"), out var __jsonRegistrationDefinition) ? Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.RegistrationAssignmentPropertiesRegistrationDefinition.FromJson(__jsonRegistrationDefinition) : RegistrationDefinition; } { _registrationDefinitionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("registrationDefinitionId"), out var __jsonRegistrationDefinitionId) ? (string)__jsonRegistrationDefinitionId : (string)RegistrationDefinitionId; } { _provisioningState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("provisioningState"), out var __jsonProvisioningState) ? (string)__jsonProvisioningState : (string)ProvisioningState; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="ErrorDefinition" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal ErrorDefinition(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _code = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("code"), out var __jsonCode) ? (string)__jsonCode : (string)Code; } { _message = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("message"), out var __jsonMessage) ? (string)__jsonMessage : (string)Message; } { _detail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("details"), out var __jsonDetails) ? If(__jsonDetails as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IErrorDefinition[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IErrorDefinition)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.ErrorDefinition.FromJson(__u)))))() : null : Detail; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="JustInTimeAccessPolicy" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal JustInTimeAccessPolicy(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _multiFactorAuthProvider = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("multiFactorAuthProvider"), out var __jsonMultiFactorAuthProvider) ? (string)__jsonMultiFactorAuthProvider : (string)MultiFactorAuthProvider; } { _maximumActivationDuration = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("maximumActivationDuration"), out var __jsonMaximumActivationDuration) ? global::System.Xml.XmlConvert.ToTimeSpan(__jsonMaximumActivationDuration) : MaximumActivationDuration; } { _managedByTenantApprover = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("managedByTenantApprovers"), out var __jsonManagedByTenantApprovers) ? If(__jsonManagedByTenantApprovers as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleApprover[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleApprover)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.EligibleApprover.FromJson(__u)))))() : null : ManagedByTenantApprover; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="RegistrationAssignment" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal RegistrationAssignment(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _property = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject>("properties"), out var __jsonProperties) ? Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.RegistrationAssignmentProperties.FromJson(__jsonProperties) : Property; } { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; } { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="Authorization" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal Authorization(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _principalId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalId"), out var __jsonPrincipalId) ? (string)__jsonPrincipalId : (string)PrincipalId; } { _principalIdDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalIdDisplayName"), out var __jsonPrincipalIdDisplayName) ? (string)__jsonPrincipalIdDisplayName : (string)PrincipalIdDisplayName; } { _roleDefinitionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("roleDefinitionId"), out var __jsonRoleDefinitionId) ? (string)__jsonRoleDefinitionId : (string)RoleDefinitionId; } { _delegatedRoleDefinitionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("delegatedRoleDefinitionIds"), out var __jsonDelegatedRoleDefinitionIds) ? If(__jsonDelegatedRoleDefinitionIds as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.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.ManagedServices.Runtime.Json.JsonString __t ? (string)(__t.ToString()) : null))))() : null : DelegatedRoleDefinitionId; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="EligibleAuthorization" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal EligibleAuthorization(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _justInTimeAccessPolicy = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject>("justInTimeAccessPolicy"), out var __jsonJustInTimeAccessPolicy) ? Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.JustInTimeAccessPolicy.FromJson(__jsonJustInTimeAccessPolicy) : JustInTimeAccessPolicy; } { _principalId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalId"), out var __jsonPrincipalId) ? (string)__jsonPrincipalId : (string)PrincipalId; } { _principalIdDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("principalIdDisplayName"), out var __jsonPrincipalIdDisplayName) ? (string)__jsonPrincipalIdDisplayName : (string)PrincipalIdDisplayName; } { _roleDefinitionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("roleDefinitionId"), out var __jsonRoleDefinitionId) ? (string)__jsonRoleDefinitionId : (string)RoleDefinitionId; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="Plan" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal Plan(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; } { _publisher = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("publisher"), out var __jsonPublisher) ? (string)__jsonPublisher : (string)Publisher; } { _product = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("product"), out var __jsonProduct) ? (string)__jsonProduct : (string)Product; } { _version = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("version"), out var __jsonVersion) ? (string)__jsonVersion : (string)Version; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="OperationDisplay" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal OperationDisplay(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _provider = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("provider"), out var __jsonProvider) ? (string)__jsonProvider : (string)Provider; } { _resource = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("resource"), out var __jsonResource) ? (string)__jsonResource : (string)Resource; } { _operation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("operation"), out var __jsonOperation) ? (string)__jsonOperation : (string)Operation; } { _description = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("description"), out var __jsonDescription) ? (string)__jsonDescription : (string)Description; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="ManagedServicesIdentity" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal ManagedServicesIdentity(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _scope = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("scope"), out var __jsonScope) ? (string)__jsonScope : (string)Scope; } { _registrationDefinitionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("registrationDefinitionId"), out var __jsonRegistrationDefinitionId) ? (string)__jsonRegistrationDefinitionId : (string)RegistrationDefinitionId; } { _registrationAssignmentId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("registrationAssignmentId"), out var __jsonRegistrationAssignmentId) ? (string)__jsonRegistrationAssignmentId : (string)RegistrationAssignmentId; } { _marketplaceIdentifier = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("marketplaceIdentifier"), out var __jsonMarketplaceIdentifier) ? (string)__jsonMarketplaceIdentifier : (string)MarketplaceIdentifier; } { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="ErrorResponse" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal ErrorResponse(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _error = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject>("error"), out var __jsonError) ? Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.ErrorDefinition.FromJson(__jsonError) : Error; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="RegistrationAssignmentPropertiesRegistrationDefinitionProperties" /// />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal RegistrationAssignmentPropertiesRegistrationDefinitionProperties(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _description = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("description"), out var __jsonDescription) ? (string)__jsonDescription : (string)Description; } { _authorization = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("authorizations"), out var __jsonAuthorizations) ? If(__jsonAuthorizations as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IAuthorization[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IAuthorization)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.Authorization.FromJson(__u)))))() : null : Authorization; } { _eligibleAuthorization = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("eligibleAuthorizations"), out var __jsonEligibleAuthorizations) ? If(__jsonEligibleAuthorizations as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleAuthorization[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleAuthorization)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.EligibleAuthorization.FromJson(__p)))))() : null : EligibleAuthorization; } { _registrationDefinitionName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("registrationDefinitionName"), out var __jsonRegistrationDefinitionName) ? (string)__jsonRegistrationDefinitionName : (string)RegistrationDefinitionName; } { _provisioningState = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("provisioningState"), out var __jsonProvisioningState) ? (string)__jsonProvisioningState : (string)ProvisioningState; } { _manageeTenantId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("manageeTenantId"), out var __jsonManageeTenantId) ? (string)__jsonManageeTenantId : (string)ManageeTenantId; } { _manageeTenantName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("manageeTenantName"), out var __jsonManageeTenantName) ? (string)__jsonManageeTenantName : (string)ManageeTenantName; } { _managedByTenantId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("managedByTenantId"), out var __jsonManagedByTenantId) ? (string)__jsonManagedByTenantId : (string)ManagedByTenantId; } { _managedByTenantName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("managedByTenantName"), out var __jsonManagedByTenantName) ? (string)__jsonManagedByTenantName : (string)ManagedByTenantName; } AfterFromJson(json); }
/// <summary> /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject into a new instance of <see cref="MarketplaceRegistrationDefinitionProperties" />. /// </summary> /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject instance to deserialize from.</param> internal MarketplaceRegistrationDefinitionProperties(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonObject json) { bool returnNow = false; BeforeFromJson(json, ref returnNow); if (returnNow) { return; } { _managedByTenantId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("managedByTenantId"), out var __jsonManagedByTenantId) ? (string)__jsonManagedByTenantId : (string)ManagedByTenantId; } { _authorization = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("authorizations"), out var __jsonAuthorizations) ? If(__jsonAuthorizations as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IAuthorization[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IAuthorization)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.Authorization.FromJson(__u)))))() : null : Authorization; } { _eligibleAuthorization = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray>("eligibleAuthorizations"), out var __jsonEligibleAuthorizations) ? If(__jsonEligibleAuthorizations as Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonArray, out var __q) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleAuthorization[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p) => (Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.IEligibleAuthorization)(Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Models.Api20200201Preview.EligibleAuthorization.FromJson(__p)))))() : null : EligibleAuthorization; } { _offerDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("offerDisplayName"), out var __jsonOfferDisplayName) ? (string)__jsonOfferDisplayName : (string)OfferDisplayName; } { _publisherDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("publisherDisplayName"), out var __jsonPublisherDisplayName) ? (string)__jsonPublisherDisplayName : (string)PublisherDisplayName; } { _planDisplayName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.ManagedServices.Runtime.Json.JsonString>("planDisplayName"), out var __jsonPlanDisplayName) ? (string)__jsonPlanDisplayName : (string)PlanDisplayName; } AfterFromJson(json); }