Package io.vertigo.commons.peg
Interface PegSolver<S,I,R>
- Type Parameters:
S- Raw data typeI- Qualified data typeR- Result type
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Generic interface for a solver that uses a function to transform raw data into a qualified value and then returns a result.
- Author:
- skerdudou
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic <S,I, I2, R>
PegSolver<S, I, R> flattenSolvers(PegSolver<PegSolver<S, I, I2>, I2, R> nestedSolver) Forward the PegSolverFunction to the nested solver and return the PegSolver resolving both levels.
-
Method Details
-
apply
- Throws:
PegParsingValueException
-
flattenSolvers
static <S,I, PegSolver<S,I2, R> I, flattenSolversR> (PegSolver<PegSolver<S, I, I2>, I2, R> nestedSolver) Forward the PegSolverFunction to the nested solver and return the PegSolver resolving both levels.- Type Parameters:
S- Raw data typeI- Qualified data typeI2- Nested qualified data typeR- Result type- Parameters:
nestedSolver- the nested solver- Returns:
- the solver that resolve both levels
-