Package org.apache.maven.api.cli.mvn
Interface MavenParser<R extends MavenInvokerRequest<? extends MavenOptions>>
- Type Parameters:
R- The specific type of MavenInvokerRequest this parser produces
- All Superinterfaces:
Parser<R>
- All Known Subinterfaces:
ForkedMavenParser
- All Known Implementing Classes:
BaseMavenParser,DefaultForkedMavenParser,DefaultMavenParser
@Experimental
public interface MavenParser<R extends MavenInvokerRequest<? extends MavenOptions>>
extends Parser<R>
Defines the contract for parsing Maven-specific command-line arguments and creating a MavenInvokerRequest.
This interface extends the general
Parser interface, specializing it for Maven operations.- Since:
- 4.0.0
-
Method Summary
Modifier and TypeMethodDescriptionparse(ParserRequest parserRequest) Parses the givenParserRequestto create aMavenInvokerRequest.
-
Method Details
-
parse
Parses the givenParserRequestto create aMavenInvokerRequest. This method is responsible for interpreting the contents of the ParserRequest and constructing the appropriateMavenInvokerRequestobject for Maven operations.- Specified by:
parsein interfaceParser<R extends MavenInvokerRequest<? extends MavenOptions>>- Parameters:
parserRequest- the request containing all necessary information for parsing- Returns:
- the parsed
MavenInvokerRequest - Throws:
ParserException- if there's an error during parsing of the requestIOException- if there's an I/O error during the parsing process
-