Package dev.yasint.regexsynth.ast
Class Numeric
java.lang.Object
dev.yasint.regexsynth.ast.Numeric
public final class Numeric
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description Numeric() -
Method Summary
Modifier and Type Method Description static ExpressionintegerRange(int from, int to)Creates a ranged integer based on from and to values inclusively.static ExpressionleadingZero(Expression another)Appends a optional zero to any expression where usually this is used with digits/ranges.
-
Constructor Details
-
Numeric
public Numeric()
-
-
Method Details
-
leadingZero
Appends a optional zero to any expression where usually this is used with digits/ranges.- Parameters:
another- expression- Returns:
- expression with optional leading zero
-
integerRange
Creates a ranged integer based on from and to values inclusively. The resulting expression is wrapped around a non-capturing group to avoid condition collisions.- Parameters:
from- starting integerto- ending integer- Returns:
- range expression
-