mirror of
https://gitee.com/dcren/initializr.git
synced 2026-06-25 14:54:04 +08:00
Migrate ProjectDescription to an interface
This commit migrates ProjectDescription to an interface with read-only accessors and create a MutableProjectDescription implementation that can be used for both purposes. As a result, the type separation between ResolvedProjectDescription and ProjectDescription is no longer necessary. Closes gh-993
This commit is contained in:
@@ -25,7 +25,7 @@ import io.spring.initializr.generator.io.template.MustacheTemplateRenderer;
|
||||
import io.spring.initializr.generator.language.Language;
|
||||
import io.spring.initializr.generator.language.java.JavaLanguage;
|
||||
import io.spring.initializr.generator.project.DefaultProjectAssetGenerator;
|
||||
import io.spring.initializr.generator.project.ProjectDescription;
|
||||
import io.spring.initializr.generator.project.MutableProjectDescription;
|
||||
import io.spring.initializr.generator.project.ProjectGenerator;
|
||||
import io.spring.initializr.generator.version.Version;
|
||||
import io.spring.initializr.metadata.InitializrMetadata;
|
||||
@@ -62,8 +62,8 @@ class ProjectGeneratorSetupExampleTests {
|
||||
assertThat(helloFile).exists().isRegularFile().hasContent("Test");
|
||||
}
|
||||
|
||||
private ProjectDescription createProjectDescription() {
|
||||
ProjectDescription description = new ProjectDescription();
|
||||
private MutableProjectDescription createProjectDescription() {
|
||||
MutableProjectDescription description = new MutableProjectDescription();
|
||||
description.setGroupId("com.example");
|
||||
description.setArtifactId("demo");
|
||||
description.setApplicationName("DemoApplication");
|
||||
|
||||
Reference in New Issue
Block a user