Package org.microproxy.stats
Record Class TagExtractor.Rule
java.lang.Object
java.lang.Record
org.microproxy.stats.TagExtractor.Rule
- Record Components:
tagName- the name of the tag the rule findspattern- the expression: group 1 is removed from the name, group 2 is the value
- Enclosing class:
TagExtractor
One rule.
-
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.pattern()Returns the value of thepatternrecord component.tagName()Returns the value of thetagNamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Rule
Checks the rule.- Parameters:
tagName- the name of the tag the rule findspattern- the expression, with at least two groups- Throws:
IllegalArgumentException- if the expression has fewer than two groups
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
tagName
Returns the value of thetagNamerecord component.- Returns:
- the value of the
tagNamerecord component
-
pattern
Returns the value of thepatternrecord component.- Returns:
- the value of the
patternrecord component
-