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

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _property = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("properties"), out var __jsonProperties) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardProperties.FromJson(__jsonProperties) : Property; }
            { _tag = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("tags"), out var __jsonTags) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.PatchableDashboardTags.FromJson(__jsonTags) : Tag; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="DashboardParts" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal DashboardParts(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _position = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("position"), out var __jsonPosition) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardPartsPosition.FromJson(__jsonPosition) : Position; }
            { _metadata = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("metadata"), out var __jsonMetadata) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardPartsMetadata.FromJson(__jsonMetadata) : Metadata; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="DashboardListResult" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal DashboardListResult(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _nextLink = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("nextLink"), out var __jsonNextLink) ? (string)__jsonNextLink : (string)NextLink; }
            { _value = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonArray>("value"), out var __jsonValue) ? If(__jsonValue as Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.IDashboard[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.IDashboard)(Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.Dashboard.FromJson(__u)))))() : null : Value; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="DashboardProperties" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal DashboardProperties(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _lens = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("lenses"), out var __jsonLenses) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardPropertiesLenses.FromJson(__jsonLenses) : Lens; }
            { _metadata = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("metadata"), out var __jsonMetadata) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardPropertiesMetadata.FromJson(__jsonMetadata) : Metadata; }
            AfterFromJson(json);
        }
Example #5
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="ResourceProviderOperation" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal ResourceProviderOperation(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _display = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("display"), out var __jsonDisplay) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.ResourceProviderOperationDisplay.FromJson(__jsonDisplay) : Display; }
            { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; }
            { _isDataAction = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("isDataAction"), out var __jsonIsDataAction) ? (string)__jsonIsDataAction : (string)IsDataAction; }
            AfterFromJson(json);
        }
Example #6
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="DashboardLens" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal DashboardLens(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _metadata = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("metadata"), out var __jsonMetadata) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardLensMetadata.FromJson(__jsonMetadata) : Metadata; }
            { _order = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonNumber>("order"), out var __jsonOrder) ? (int)__jsonOrder : Order; }
            { _part = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("parts"), out var __jsonParts) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardLensParts.FromJson(__jsonParts) : Part; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="ErrorDefinition" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal ErrorDefinition(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _code = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("code"), out var __jsonCode) ? (string)__jsonCode : (string)Code; }
            { _message = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("message"), out var __jsonMessage) ? (string)__jsonMessage : (string)Message; }
            { _detail = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonArray>("details"), out var __jsonDetails) ? If(__jsonDetails as Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonArray, out var __v) ? new global::System.Func <Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.IErrorDefinition[]>(() => global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u) => (Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.IErrorDefinition)(Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.ErrorDefinition.FromJson(__u)))))() : null : Detail; }
            AfterFromJson(json);
        }
Example #8
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="ResourceProviderOperationDisplay" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal ResourceProviderOperationDisplay(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _description = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("description"), out var __jsonDescription) ? (string)__jsonDescription : (string)Description; }
            { _operation = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("operation"), out var __jsonOperation) ? (string)__jsonOperation : (string)Operation; }
            { _provider = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("provider"), out var __jsonProvider) ? (string)__jsonProvider : (string)Provider; }
            { _resource = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("resource"), out var __jsonResource) ? (string)__jsonResource : (string)Resource; }
            AfterFromJson(json);
        }
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="PortalIdentity" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal PortalIdentity(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _dashboardName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("dashboardName"), out var __jsonDashboardName) ? (string)__jsonDashboardName : (string)DashboardName; }
            { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; }
            { _resourceGroupName = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("resourceGroupName"), out var __jsonResourceGroupName) ? (string)__jsonResourceGroupName : (string)ResourceGroupName; }
            { _subscriptionId = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("subscriptionId"), out var __jsonSubscriptionId) ? (string)__jsonSubscriptionId : (string)SubscriptionId; }
            AfterFromJson(json);
        }
Example #10
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="DashboardPartsPosition" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal DashboardPartsPosition(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _colSpan = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonNumber>("colSpan"), out var __jsonColSpan) ? (int)__jsonColSpan : ColSpan; }
            { _metadata = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("metadata"), out var __jsonMetadata) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardPartsPositionMetadata.FromJson(__jsonMetadata) : Metadata; }
            { _rowSpan = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonNumber>("rowSpan"), out var __jsonRowSpan) ? (int)__jsonRowSpan : RowSpan; }
            { _x = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonNumber>("x"), out var __jsonX) ? (int)__jsonX : X; }
            { _y = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonNumber>("y"), out var __jsonY) ? (int)__jsonY : Y; }
            AfterFromJson(json);
        }
Example #11
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="ErrorResponse" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal ErrorResponse(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _error = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("error"), out var __jsonError) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.ErrorDefinition.FromJson(__jsonError) : Error; }
            AfterFromJson(json);
        }
Example #12
0
        /// <summary>
        /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject into a new instance of <see cref="Dashboard" />.
        /// </summary>
        /// <param name="json">A Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject instance to deserialize from.</param>
        internal Dashboard(Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject json)
        {
            bool returnNow = false;

            BeforeFromJson(json, ref returnNow);
            if (returnNow)
            {
                return;
            }
            { _property = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("properties"), out var __jsonProperties) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardProperties.FromJson(__jsonProperties) : Property; }
            { _name = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("name"), out var __jsonName) ? (string)__jsonName : (string)Name; }
            { _type = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("type"), out var __jsonType) ? (string)__jsonType : (string)Type; }
            { _id = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("id"), out var __jsonId) ? (string)__jsonId : (string)Id; }
            { _location = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonString>("location"), out var __jsonLocation) ? (string)__jsonLocation : (string)Location; }
            { _tag = If(json?.PropertyT <Microsoft.Azure.PowerShell.Cmdlets.Portal.Runtime.Json.JsonObject>("tags"), out var __jsonTags) ? Microsoft.Azure.PowerShell.Cmdlets.Portal.Models.Api201901Preview.DashboardTags.FromJson(__jsonTags) : Tag; }
            AfterFromJson(json);
        }