< Summary

Information
Class: TeleFlow.Telegram.Internal.Handlers.TelegramHandlerCandidate
Assembly: TeleFlow.Framework
File(s): /_/src/TeleFlow.Framework/Internal/Handlers/TelegramHandlerCandidate.cs
Line coverage
100%
Covered lines: 5
Uncovered lines: 0
Coverable lines: 5
Total lines: 21
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
Create(...)100%11100%

File(s)

/_/src/TeleFlow.Framework/Internal/Handlers/TelegramHandlerCandidate.cs

#LineLine coverage
 1namespace TeleFlow.Telegram.Internal.Handlers;
 2
 3/// <summary>
 4/// Represents a prepared handler route candidate selected from the handler table before per-update route
 5/// matching, filter evaluation, and handler invocation.
 6/// </summary>
 7internal readonly record struct TelegramHandlerCandidate(
 8    TelegramHandlerDescriptor Handler,
 9    TelegramRouteDescriptor Route,
 10    TelegramRouteFilterPlan Filters)
 11{
 12    public static TelegramHandlerCandidate Create(TelegramHandlerDescriptor handler)
 13    {
 109214        ArgumentNullException.ThrowIfNull(handler);
 15
 109216        return new TelegramHandlerCandidate(
 109217            handler,
 109218            handler.Route,
 109219            TelegramRouteFilterPlan.Create(handler.Route));
 20    }
 21}