< Summary

Information
Class: Hertzole.ScriptableValues.Generator.DiagnosticRules
Assembly: Hertzole.ScriptableValues.Generator
File(s): Generator/Hertzole.ScriptableValues.Generator/Analyzers/Common/DiagnosticRules.cs
Tag: 52_28197466029
Line coverage
0%
Covered lines: 0
Uncovered lines: 55
Coverable lines: 55
Total lines: 71
Line coverage: 0%
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 Cyclomatic complexity NPath complexity Sequence coverage
.cctor()100%110%

File(s)

Generator/Hertzole.ScriptableValues.Generator/Analyzers/Common/DiagnosticRules.cs

#LineLine coverage
 1using Microsoft.CodeAnalysis;
 2
 3namespace Hertzole.ScriptableValues.Generator;
 4
 5internal static class DiagnosticRules
 6{
 07    private static readonly LocalizableResourceString noCallbackImplementationTitle = new LocalizableResourceString(
 08        nameof(Resources.HSV0001Title), Resources.ResourceManager, typeof(Resources));
 09    private static readonly LocalizableResourceString noCallbackImplementationMessage = new LocalizableResourceString(
 010        nameof(Resources.HSV0001MessageFormat), Resources.ResourceManager, typeof(Resources));
 11
 012    private static readonly LocalizableResourceString noMarkerAttributeTiler = new LocalizableResourceString(
 013        nameof(Resources.HSV0002Title), Resources.ResourceManager, typeof(Resources));
 014    private static readonly LocalizableResourceString noMarkerAttributeMessage = new LocalizableResourceString(
 015        nameof(Resources.HSV0002Message), Resources.ResourceManager, typeof(Resources));
 16
 017    private static readonly LocalizableResourceString typeNotSupportedForCallbackAttributeTitle = new LocalizableResourc
 018        nameof(Resources.HSV0100Title), Resources.ResourceManager, typeof(Resources));
 019    private static readonly LocalizableResourceString typeNotSupportedForCallbackAttributeMessage = new LocalizableResou
 020        nameof(Resources.HSV0100MessageFormat), Resources.ResourceManager, typeof(Resources));
 21
 022    private static readonly LocalizableResourceString typeNotSupportedTitle = new LocalizableResourceString(
 023        nameof(Resources.HSV0101Title), Resources.ResourceManager, typeof(Resources));
 024    private static readonly LocalizableResourceString typeNotSupportedMessage = new LocalizableResourceString(
 025        nameof(Resources.HSV0101MessageFormat), Resources.ResourceManager, typeof(Resources));
 26
 027    private static readonly LocalizableResourceString incorrectAttributeUsageTitle = new LocalizableResourceString(
 028        nameof(Resources.HSV0102Title), Resources.ResourceManager, typeof(Resources));
 029    private static readonly LocalizableResourceString incorrectAttributeUsageMessage = new LocalizableResourceString(
 030        nameof(Resources.HSV0102MessageFormat), Resources.ResourceManager, typeof(Resources));
 31
 032    public static readonly DiagnosticDescriptor NoCallbackImplementation = new DiagnosticDescriptor(
 033        DiagnosticIdentifiers.NoCallbackImplementation,
 034        noCallbackImplementationTitle,
 035        noCallbackImplementationMessage,
 036        DiagnosticCategories.Usage,
 037        DiagnosticSeverity.Error,
 038        true);
 39
 040    public static readonly DiagnosticDescriptor NoMarkerAttribute = new DiagnosticDescriptor(
 041        DiagnosticIdentifiers.NoMarkerAttribute,
 042        noMarkerAttributeTiler,
 043        noMarkerAttributeMessage,
 044        DiagnosticCategories.Usage,
 045        DiagnosticSeverity.Warning,
 046        true);
 47
 048    public static readonly DiagnosticDescriptor TypeNotSupportedForCallbackAttribute = new DiagnosticDescriptor(
 049        DiagnosticIdentifiers.TypeNotSupportedForCallbackAttribute,
 050        typeNotSupportedForCallbackAttributeTitle,
 051        typeNotSupportedForCallbackAttributeMessage,
 052        DiagnosticCategories.Usage,
 053        DiagnosticSeverity.Error,
 054        true);
 55
 056    public static readonly DiagnosticDescriptor TypeNotSupported = new DiagnosticDescriptor(
 057        DiagnosticIdentifiers.TypeNotSupported,
 058        typeNotSupportedTitle,
 059        typeNotSupportedMessage,
 060        DiagnosticCategories.Usage,
 061        DiagnosticSeverity.Error,
 062        true);
 63
 064    public static readonly DiagnosticDescriptor IncorrectAttributeUsage = new DiagnosticDescriptor(
 065        DiagnosticIdentifiers.IncorrectAttributeUsage,
 066        incorrectAttributeUsageTitle,
 067        incorrectAttributeUsageMessage,
 068        DiagnosticCategories.Usage,
 069        DiagnosticSeverity.Error,
 070        true);
 71}

Methods/Properties

.cctor()