< Summary

Class:Azure.Messaging.EventGrid.SystemEvents.WebAppServicePlanUpdatedEventData
Assembly:Azure.Messaging.EventGrid
File(s):C:\Git\azure-sdk-for-net\sdk\eventgrid\Azure.Messaging.EventGrid\src\Generated\Models\WebAppServicePlanUpdatedEventData.cs
C:\Git\azure-sdk-for-net\sdk\eventgrid\Azure.Messaging.EventGrid\src\Generated\Models\WebAppServicePlanUpdatedEventData.Serialization.cs
Covered lines:42
Uncovered lines:11
Coverable lines:53
Total lines:127
Line coverage:79.2% (42 of 53)
Covered branches:17
Total branches:18
Branch coverage:94.4% (17 of 18)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-100%100%
get_AppServicePlanEventTypeDetail()-0%100%
get_Sku()-0%100%
get_Name()-100%100%
get_ClientRequestId()-0%100%
get_CorrelationRequestId()-0%100%
get_RequestId()-0%100%
get_Address()-0%100%
get_Verb()-0%100%
DeserializeWebAppServicePlanUpdatedEventData(...)-93.94%94.44%

File(s)

C:\Git\azure-sdk-for-net\sdk\eventgrid\Azure.Messaging.EventGrid\src\Generated\Models\WebAppServicePlanUpdatedEventData.cs

#LineLine coverage
 1// Copyright (c) Microsoft Corporation. All rights reserved.
 2// Licensed under the MIT License.
 3
 4// <auto-generated/>
 5
 6#nullable disable
 7
 8namespace Azure.Messaging.EventGrid.SystemEvents
 9{
 10    /// <summary> Schema of the Data property of an EventGridEvent for an Microsoft.Web.AppServicePlanUpdated event. </s
 11    public partial class WebAppServicePlanUpdatedEventData
 12    {
 13        /// <summary> Initializes a new instance of WebAppServicePlanUpdatedEventData. </summary>
 014        internal WebAppServicePlanUpdatedEventData()
 15        {
 016        }
 17
 18        /// <summary> Initializes a new instance of WebAppServicePlanUpdatedEventData. </summary>
 19        /// <param name="appServicePlanEventTypeDetail"> Detail of action on the app service plan. </param>
 20        /// <param name="sku"> sku of app service plan. </param>
 21        /// <param name="name"> name of the app service plan that had this event. </param>
 22        /// <param name="clientRequestId"> The client request id generated by the app service for the app service plan A
 23        /// <param name="correlationRequestId"> The correlation request id generated by the app service for the app serv
 24        /// <param name="requestId"> The request id generated by the app service for the app service plan API operation 
 25        /// <param name="address"> HTTP request URL of this operation. </param>
 26        /// <param name="verb"> HTTP verb of this operation. </param>
 227        internal WebAppServicePlanUpdatedEventData(AppServicePlanEventTypeDetail appServicePlanEventTypeDetail, WebAppSe
 28        {
 229            AppServicePlanEventTypeDetail = appServicePlanEventTypeDetail;
 230            Sku = sku;
 231            Name = name;
 232            ClientRequestId = clientRequestId;
 233            CorrelationRequestId = correlationRequestId;
 234            RequestId = requestId;
 235            Address = address;
 236            Verb = verb;
 237        }
 38
 39        /// <summary> Detail of action on the app service plan. </summary>
 040        public AppServicePlanEventTypeDetail AppServicePlanEventTypeDetail { get; }
 41        /// <summary> sku of app service plan. </summary>
 042        public WebAppServicePlanUpdatedEventDataSku Sku { get; }
 43        /// <summary> name of the app service plan that had this event. </summary>
 244        public string Name { get; }
 45        /// <summary> The client request id generated by the app service for the app service plan API operation that tri
 046        public string ClientRequestId { get; }
 47        /// <summary> The correlation request id generated by the app service for the app service plan API operation tha
 048        public string CorrelationRequestId { get; }
 49        /// <summary> The request id generated by the app service for the app service plan API operation that triggered 
 050        public string RequestId { get; }
 51        /// <summary> HTTP request URL of this operation. </summary>
 052        public string Address { get; }
 53        /// <summary> HTTP verb of this operation. </summary>
 054        public string Verb { get; }
 55    }
 56}

C:\Git\azure-sdk-for-net\sdk\eventgrid\Azure.Messaging.EventGrid\src\Generated\Models\WebAppServicePlanUpdatedEventData.Serialization.cs

#LineLine coverage
 1// Copyright (c) Microsoft Corporation. All rights reserved.
 2// Licensed under the MIT License.
 3
 4// <auto-generated/>
 5
 6#nullable disable
 7
 8using System.Text.Json;
 9using Azure.Core;
 10
 11namespace Azure.Messaging.EventGrid.SystemEvents
 12{
 13    public partial class WebAppServicePlanUpdatedEventData
 14    {
 15        internal static WebAppServicePlanUpdatedEventData DeserializeWebAppServicePlanUpdatedEventData(JsonElement eleme
 16        {
 217            Optional<AppServicePlanEventTypeDetail> appServicePlanEventTypeDetail = default;
 218            Optional<WebAppServicePlanUpdatedEventDataSku> sku = default;
 219            Optional<string> name = default;
 220            Optional<string> clientRequestId = default;
 221            Optional<string> correlationRequestId = default;
 222            Optional<string> requestId = default;
 223            Optional<string> address = default;
 224            Optional<string> verb = default;
 3225            foreach (var property in element.EnumerateObject())
 26            {
 1427                if (property.NameEquals("appServicePlanEventTypeDetail"))
 28                {
 229                    appServicePlanEventTypeDetail = AppServicePlanEventTypeDetail.DeserializeAppServicePlanEventTypeDeta
 230                    continue;
 31                }
 1232                if (property.NameEquals("sku"))
 33                {
 034                    sku = WebAppServicePlanUpdatedEventDataSku.DeserializeWebAppServicePlanUpdatedEventDataSku(property.
 035                    continue;
 36                }
 1237                if (property.NameEquals("name"))
 38                {
 239                    name = property.Value.GetString();
 240                    continue;
 41                }
 1042                if (property.NameEquals("clientRequestId"))
 43                {
 244                    clientRequestId = property.Value.GetString();
 245                    continue;
 46                }
 847                if (property.NameEquals("correlationRequestId"))
 48                {
 249                    correlationRequestId = property.Value.GetString();
 250                    continue;
 51                }
 652                if (property.NameEquals("requestId"))
 53                {
 254                    requestId = property.Value.GetString();
 255                    continue;
 56                }
 457                if (property.NameEquals("address"))
 58                {
 259                    address = property.Value.GetString();
 260                    continue;
 61                }
 262                if (property.NameEquals("verb"))
 63                {
 264                    verb = property.Value.GetString();
 65                    continue;
 66                }
 67            }
 268            return new WebAppServicePlanUpdatedEventData(appServicePlanEventTypeDetail.Value, sku.Value, name.Value, cli
 69        }
 70    }
 71}