Record Class SarifLogger.RuleKey
java.lang.Object
java.lang.Record
com.puppycrawl.tools.checkstyle.SarifLogger.RuleKey
- Record Components:
sourceName- The fully qualified source class name.moduleId- The module ID from configuration (can be null).
- Enclosing class:
SarifLogger
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final StringThe field for themoduleIdrecord component.private final StringThe field for thesourceNamerecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.moduleId()Returns the value of themoduleIdrecord component.Returns the value of thesourceNamerecord component.private StringtoRuleId()Converts this key to a SARIF rule ID string.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
sourceName
The field for thesourceNamerecord component. -
moduleId
-
-
Constructor Details
-
RuleKey
Creates an instance of aRuleKeyrecord class.- Parameters:
sourceName- the value for thesourceNamerecord componentmoduleId- the value for themoduleIdrecord component
-
-
Method Details
-
toRuleId
Converts this key to a SARIF rule ID string.- Returns:
- rule ID in format: sourceName[#moduleId]
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
sourceName
Returns the value of thesourceNamerecord component.- Returns:
- the value of the
sourceNamerecord component
-
moduleId
-