@ NotNull public static SrcGen4JConfig createMavenStyleSingleProject ( @ NotNull final SrcGen4JContext context , @ NotNull final String projectName , @ NotNull @ FileExists @ IsDirectory final File rootDir ) { Contract . requireArgNotNull ( "context" , context ) ; Contract . requireArgNotNull ( ROOT_DIR_VAR , rootDir ) ; FileExistsValidator . requireArgValid ( ROOT_DIR_VAR , rootDir ) ; IsDirectoryValidator . requireArgValid ( ROOT_DIR_VAR , rootDir ) ; Contract . requireArgNotNull ( "projectName" , projectName ) ; final SrcGen4JConfig config = new SrcGen4JConfig ( ) ; final List < Project > projects = new ArrayList <> ( ) ; final Project project = new Project ( projectName , "." ) ; project . setMaven ( true ) ; projects . add ( project ) ; config . setProjects ( projects ) ; config . init ( context , rootDir ) ; return config ; }
Creates a new configuration with a single project and a Maven directory structure .