Package org.apache.camel.dsl.modeline
Class JBangModelineParser
java.lang.Object
org.apache.camel.dsl.modeline.JBangModelineParser
- All Implemented Interfaces:
ModelineParser
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisModeline(String line) Is the given source code line a modeline?protected List<org.apache.camel.spi.CamelContextCustomizer> List<org.apache.camel.spi.CamelContextCustomizer> parse(org.apache.camel.spi.Resource resource) Parses the resource to detect modelines
-
Field Details
-
JBANG_DEPS_START
- See Also:
-
-
Constructor Details
-
JBangModelineParser
public JBangModelineParser()
-
-
Method Details
-
parse
public List<org.apache.camel.spi.CamelContextCustomizer> parse(org.apache.camel.spi.Resource resource) throws Exception Description copied from interface:ModelineParserParses the resource to detect modelines- Specified by:
parsein interfaceModelineParser- Parameters:
resource- the source code resource- Returns:
- list of
CamelContextCustomizercustomizers that processes the modelines - Throws:
Exception- is thrown if error during parsing
-
isModeline
Description copied from interface:ModelineParserIs the given source code line a modeline?- Specified by:
isModelinein interfaceModelineParser- Parameters:
line- the source code line- Returns:
- true if modeline, false if not
-
parse
-