CorpusCategory enum
What role a CorpusCase plays in measuring correctness.
The category decides how the metrics harness scores the case (see the precision/recall harness): positive cases must be caught, while clean and adversarial cases must stay silent.
Values
- positive → const CorpusCategory
-
A screen containing exactly one known violation of the rule under test. The signal is isolated so a miss is unambiguous.
- clean → const CorpusCategory
-
A correct screen that must produce zero findings for the rule under test. Guards against false positives and is as important as a positive case.
- adversarial → const CorpusCategory
-
A known false-positive trap for the rule under test (text over a gradient, a disabled control, a decorative-but-excluded image, an RTL layout). The rule must stay silent; any finding is a false positive.
- realWorld → const CorpusCategory
-
A composite, realistic screen audited with every rule enabled and labelled across all of them. Surfaces the messy cases synthetic fixtures miss.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- index → int
-
A numeric identifier for the enumerated value.
no setterinherited
- name → String
-
Available on Enum, provided by the EnumName extension
The name of the enum value.no setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → String - The JSON representation of this category (its name).
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJson(
String json) → CorpusCategory - Parses a CorpusCategory from its name.
Constants
-
values
→ const List<
CorpusCategory> - A constant List of the values in this enum, in order of their declaration.