Class AddAggregateMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

    @Mojo(name="add-aggregate",
          requiresDependencyResolution=COMPILE_PLUS_RUNTIME,
          requiresDependencyCollection=COMPILE_PLUS_RUNTIME,
          requiresDirectInvocation=true)
    public class AddAggregateMojo
    extends org.apache.maven.plugin.AbstractMojo

    Generates all required classes to represent a new Aggregate. Given Aggregate name MyAggregate, the following classes will be created:

    • MyAggregate: the Aggregate Root,
    • MyAggregateId: the Aggregate's identifier type,
    • MyAggregateFactory: the Aggregate Factory,
    • MyAggregateRepository: the Aggregate Repository,
    • MyAggregateDataAccess: the interface describing Repository's requirements for commands and queries on stored data,
    • MyAggregateAttributes: the implementation for Aggregate's attributes (i.e. the data actually stored).

    Depending on chosen storage adapters, additional specific classes may be created in addition to the list mentioned above.

    • Field Summary

      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Constructor Detail

      • AddAggregateMojo

        public AddAggregateMojo()
    • Method Detail

      • execute

        public void execute()
                     throws org.apache.maven.plugin.MojoExecutionException
        Throws:
        org.apache.maven.plugin.MojoExecutionException