public class TokenMatcher extends Object
Constructor and Description |
---|
TokenMatcher(String regex,
String tokenMarker) |
Modifier and Type | Method and Description |
---|---|
String |
getPattern()
The regex pattern that was used for creating the regex used.
|
String |
getTokenMarker()
Delivers the token marker used for mapping.
|
String |
validateToken(String token)
Validates the given token with the compiled regex pattern.
|
public String getPattern()
public String getTokenMarker()
public String validateToken(String token) throws TokenParseException
token
- a portion of the log line as StringTokenParseException
- when a match fails.Copyright © 2017 Jason "JRSofty" Reed. All rights reserved.