Class Finding

java.lang.Object
io.codemodder.codetf.Finding
Direct Known Subclasses:
FixedFinding, UnfixedFinding

public abstract sealed class Finding extends Object permits FixedFinding, UnfixedFinding
Describes a detected finding that served as input to the codemod.

When a codemod is able to fix a finding, it should create a FixedFinding instance. If a codemod would typically fix findings of this type but cannot, it can create an UnfixedFinding instance to explain why.

Findings typically have some ID specified in the detector results.

  • Method Details

    • getId

      public String getId()
      Returns:
      the ID of the finding, or null if the finding has no ID
    • getRule

      public DetectorRule getRule()
      Returns:
      the rule that detected the finding
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object