Class SimpleRegexSyntaxHighlighter.RegexHighlightGrammarBuilder
- java.lang.Object
-
- net.sourceforge.pmd.util.fxdesigner.util.codearea.SimpleRegexSyntaxHighlighter.RegexHighlightGrammarBuilder
-
- Enclosing class:
- SimpleRegexSyntaxHighlighter
protected static final class SimpleRegexSyntaxHighlighter.RegexHighlightGrammarBuilder extends Object
Builds a highlight grammar in a concise way.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SimpleRegexSyntaxHighlighter.RegexHighlightGrammar
create()
Builds the grammar.SimpleRegexSyntaxHighlighter.RegexHighlightGrammar
create(int flags)
Builds the grammar.SimpleRegexSyntaxHighlighter.RegexHighlightGrammarBuilder
or(Collection<String> cssClass, String regex)
Adds a branch to the alternation (...|pattern).
-
-
-
Method Detail
-
or
public SimpleRegexSyntaxHighlighter.RegexHighlightGrammarBuilder or(Collection<String> cssClass, String regex)
Adds a branch to the alternation (...|pattern). Order is important.- Parameters:
cssClass
- css class that the matching regions should bearregex
- Regex pattern- Returns:
- The same builder
-
create
public SimpleRegexSyntaxHighlighter.RegexHighlightGrammar create()
Builds the grammar.- Returns:
- A new grammar
-
create
public SimpleRegexSyntaxHighlighter.RegexHighlightGrammar create(int flags)
Builds the grammar.- Parameters:
flags
- Regex compilation flags- Returns:
- A new grammar
-
-