Class AbstractKafkaHeaderMapper.SimplePatternBasedHeaderMatcher
- java.lang.Object
-
- org.springframework.kafka.support.AbstractKafkaHeaderMapper.SimplePatternBasedHeaderMatcher
-
- All Implemented Interfaces:
AbstractKafkaHeaderMapper.HeaderMatcher
- Enclosing class:
- AbstractKafkaHeaderMapper
protected static class AbstractKafkaHeaderMapper.SimplePatternBasedHeaderMatcher extends java.lang.Object implements AbstractKafkaHeaderMapper.HeaderMatcher
A pattern-based header matcher that matches if the specified header matches the specified simple pattern.The
negate == true
state indicates if the matching should be treated as "not matched".- See Also:
PatternMatchUtils.simpleMatch(String, String)
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SimplePatternBasedHeaderMatcher(java.lang.String pattern)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isNegated()
Return true if this matcher is a negative matcher.boolean
matchHeader(java.lang.String headerName)
Return true if the header matches.
-
-
-
Method Detail
-
matchHeader
public boolean matchHeader(java.lang.String headerName)
Description copied from interface:AbstractKafkaHeaderMapper.HeaderMatcher
Return true if the header matches.- Specified by:
matchHeader
in interfaceAbstractKafkaHeaderMapper.HeaderMatcher
- Parameters:
headerName
- the header name.- Returns:
- true for a match.
-
isNegated
public boolean isNegated()
Description copied from interface:AbstractKafkaHeaderMapper.HeaderMatcher
Return true if this matcher is a negative matcher.- Specified by:
isNegated
in interfaceAbstractKafkaHeaderMapper.HeaderMatcher
- Returns:
- true for a negative matcher.
-
-