public class PipelineRuleParser extends Object
| Modifier and Type | Field and Description |
|---|---|
static org.antlr.v4.runtime.tree.ParseTreeWalker |
WALKER |
| Constructor and Description |
|---|
PipelineRuleParser(FunctionRegistry functionRegistry) |
| Modifier and Type | Method and Description |
|---|---|
Pipeline |
parsePipeline(String id,
String source) |
List<Pipeline> |
parsePipelines(String pipelines) |
Rule |
parseRule(String rule,
boolean silent) |
Rule |
parseRule(String id,
String rule,
boolean silent)
Parses the given rule source and optionally generates a Java class for it if the classloader is not null.
|
static String |
unescape(String string) |
static String |
unquote(String string,
char quoteChar) |
@Inject public PipelineRuleParser(FunctionRegistry functionRegistry)
public Rule parseRule(String rule, boolean silent) throws ParseException
ParseExceptionpublic Rule parseRule(String id, String rule, boolean silent) throws ParseException
id - the id of the rule, necessary to generate coderule - rule source codesilent - don't emit status messages during parsingParseException - if a one or more parse errors occurpublic List<Pipeline> parsePipelines(String pipelines) throws ParseException
ParseExceptionCopyright © 2012–2021 Graylog, Inc.. All rights reserved.