@Mojo(name = "exampleMojo")
public class ExampleMojo extends AbstractMojo {
@Requirement
private ExampleService exampleService;
public void execute() throws MojoExecutionException, MojoFailureException {
exampleService.doSomething();
}
}
<component>
<role>com.example.ExampleService</role>
<role-hint>default</role-hint>
<implementation>com.example.DefaultExampleService</implementation>
</component>