| Modifier and Type | Field and Description |
|---|---|
protected @NotNull java.util.function.BiFunction<Document,Reference,Tree> |
constructor
The constructor of the resultant tree.
|
protected @Nullable java.util.function.BiConsumer<Tree,Reference>[] |
constructors
The constructors of the components.
|
protected @NotNull java.util.regex.Pattern |
endPattern
A pattern matching the closing sequence.
|
protected @NotNull java.util.regex.Pattern |
startPattern
A pattern matching the opening sequence.
|
protected int |
zIndex
The z-index to accept.
|
| Constructor and Description |
|---|
PatternRangeParser(@NotNull java.util.regex.Pattern startPattern,
@NotNull java.util.regex.Pattern endPattern,
@NotNull java.util.function.BiFunction<Document,Reference,Tree> constructor,
java.util.function.BiConsumer<Tree,Reference>... constructors)
Construct a new scope parser that parses the sketches looking for areas that starts
with the given
startPattern and ends with the given endPattern. |
PatternRangeParser(@NotNull java.util.regex.Pattern startPattern,
@NotNull java.util.regex.Pattern endPattern,
int zIndex,
@NotNull java.util.function.BiFunction<Document,Reference,Tree> constructor,
java.util.function.BiConsumer<Tree,Reference>... constructors)
Construct a new scope parser that parses the sketches looking for areas that starts
with the given
startPattern and ends with the given endPattern. |
| Modifier and Type | Method and Description |
|---|---|
@NotNull java.util.Set<Tree> |
parse(@NotNull Compilation compilation,
@NotNull Tree tree)
Parse the given
sketch with respect to the given compilation. |
@NotNull protected final @NotNull java.util.function.BiFunction<Document,Reference,Tree> constructor
@Nullable protected final @Nullable java.util.function.BiConsumer<Tree,Reference>[] constructors
@NotNull protected final @NotNull java.util.regex.Pattern endPattern
@NotNull protected final @NotNull java.util.regex.Pattern startPattern
protected final int zIndex
@SafeVarargs
public PatternRangeParser(@NotNull
@NotNull java.util.regex.Pattern startPattern,
@NotNull
@NotNull java.util.regex.Pattern endPattern,
int zIndex,
@NotNull
@NotNull java.util.function.BiFunction<Document,Reference,Tree> constructor,
@Nullable
java.util.function.BiConsumer<Tree,Reference>... constructors)
startPattern and ends with the given endPattern.startPattern - the pattern matching the start of the areas the constructed
parser will be looking for.endPattern - the pattern matching the end of the areas the constructed
parser will be looking for.zIndex - the z-index to accept.constructor - the constructor of the result trees.constructors - the constructors of the components.java.lang.NullPointerException - if the given startPattern or endPattern or constructor or constructors is null.java.lang.IllegalArgumentException - if constructors.length > 3.@SafeVarargs
public PatternRangeParser(@NotNull
@NotNull java.util.regex.Pattern startPattern,
@NotNull
@NotNull java.util.regex.Pattern endPattern,
@NotNull
@NotNull java.util.function.BiFunction<Document,Reference,Tree> constructor,
@Nullable
java.util.function.BiConsumer<Tree,Reference>... constructors)
startPattern and ends with the given endPattern.startPattern - the pattern matching the start of the areas the constructed
parser will be looking for.endPattern - the pattern matching the end of the areas the constructed
parser will be looking for.constructor - the constructor of the result trees.constructors - the constructors of the components.java.lang.NullPointerException - if the given startPattern or endPattern or constructor or constructors is null.java.lang.IllegalArgumentException - if constructors.length > 3.@NotNull public @NotNull java.util.Set<Tree> parse(@NotNull @NotNull Compilation compilation, @NotNull @NotNull Tree tree)
Parsersketch with respect to the given compilation.