< Summary

Class:Microsoft.Azure.ServiceBus.ExceptionReceivedEventArgs
Assembly:Microsoft.Azure.ServiceBus
File(s):C:\Git\azure-sdk-for-net\sdk\servicebus\Microsoft.Azure.ServiceBus\src\ExceptionReceivedEventArgs.cs
Covered lines:0
Uncovered lines:6
Coverable lines:6
Total lines:34
Line coverage:0% (0 of 6)
Covered branches:0
Total branches:0

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-0%100%
get_Exception()-0%100%
get_ExceptionReceivedContext()-0%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\servicebus\Microsoft.Azure.ServiceBus\src\ExceptionReceivedEventArgs.cs

#LineLine coverage
 1// Copyright (c) Microsoft. All rights reserved.
 2// Licensed under the MIT license. See LICENSE file in the project root for full license information.
 3
 4using Microsoft.Azure.ServiceBus.Core;
 5
 6namespace Microsoft.Azure.ServiceBus
 7{
 8    using System;
 9
 10    /// <summary>Provides data for the <see cref="MessageHandlerOptions.ExceptionReceivedHandler" /> event.</summary>
 11    public sealed class ExceptionReceivedEventArgs : EventArgs
 12    {
 13        /// <summary>Initializes a new instance of the <see cref="ExceptionReceivedEventArgs" /> class.</summary>
 14        /// <param name="exception">The exception that this event data belongs to.</param>
 15        /// <param name="action">The action associated with the event.</param>
 16        /// <param name="endpoint">The endpoint used when this exception occurred.</param>
 17        /// <param name="entityName">The entity path used when this exception occurred.</param>
 18        /// <param name="clientId">The Client Id can be used to associate with the <see cref="QueueClient"/>, <see cref=
 019        public ExceptionReceivedEventArgs(Exception exception, string action, string endpoint, string entityName, string
 20        {
 021            this.Exception = exception;
 022            this.ExceptionReceivedContext = new ExceptionReceivedContext(action, endpoint, entityName, clientId);
 023        }
 24
 25        /// <summary>Gets the parent class exception to which this event data belongs.</summary>
 26        /// <value>The exception, generated by the parent class, to which this event data belongs.</value>
 027        public Exception Exception { get; }
 28
 29        /// <summary>
 30        /// Gets the context of the exception (action, namespace name, and entity path).
 31        /// </summary>
 032        public ExceptionReceivedContext ExceptionReceivedContext { get; }
 33    }
 34}