Class MutableProjectDescription
java.lang.Object
io.spring.initializr.generator.project.MutableProjectDescription
- All Implemented Interfaces:
ProjectDescription
A mutable implementation of
ProjectDescription.- Author:
- Andy Wilkinson
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreate a new instance with the state of the specifiedsource. -
Method Summary
Modifier and TypeMethodDescriptionaddDependency(String id, Dependency dependency) addDependency(String id, Dependency.Builder<?> builder) Create a full copy of this description so that any additional changes made on this instance are not reflected on the returned copy.Return the name of the application as a standard Java identifier.Return the buildartifactId.Return the base directory of the project ornullto use the root directory.Return theBuildSystemto use.Return a human readable description of the project.Return the buildgroupId.Return the primaryLanguageof the project.getName()Return a simple name for the project.Return the root package name of the project.Return the buildPackagingto use.Return the requested platformVersion.Return a immutable mapping of requesteddependencies.Return the version of the project.voidsetApplicationName(String applicationName) voidsetArtifactId(String artifactId) voidsetBaseDirectory(String baseDirectory) voidsetBuildSystem(BuildSystem buildSystem) voidsetDescription(String description) voidsetGroupId(String groupId) voidsetLanguage(Language language) voidvoidsetPackageName(String packageName) voidsetPackaging(Packaging packaging) voidsetPlatformVersion(Version platformVersion) voidsetVersion(String version)
-
Constructor Details
-
MutableProjectDescription
public MutableProjectDescription() -
MutableProjectDescription
Create a new instance with the state of the specifiedsource.- Parameters:
source- the source description to initialize this instance with
-
-
Method Details
-
createCopy
Description copied from interface:ProjectDescriptionCreate a full copy of this description so that any additional changes made on this instance are not reflected on the returned copy.- Specified by:
createCopyin interfaceProjectDescription- Returns:
- a clone of this instance
-
getPlatformVersion
Description copied from interface:ProjectDescriptionReturn the requested platformVersion.- Specified by:
getPlatformVersionin interfaceProjectDescription- Returns:
- the requested platform version or
null
-
setPlatformVersion
-
getBuildSystem
Description copied from interface:ProjectDescriptionReturn theBuildSystemto use.- Specified by:
getBuildSystemin interfaceProjectDescription- Returns:
- the build system or
null
-
setBuildSystem
-
getPackaging
Description copied from interface:ProjectDescriptionReturn the buildPackagingto use.- Specified by:
getPackagingin interfaceProjectDescription- Returns:
- the build packaging or
null
-
setPackaging
-
getLanguage
Description copied from interface:ProjectDescriptionReturn the primaryLanguageof the project.- Specified by:
getLanguagein interfaceProjectDescription- Returns:
- the primary language or
null
-
setLanguage
-
addDependency
-
addDependency
-
removeDependency
-
getRequestedDependencies
Description copied from interface:ProjectDescriptionReturn a immutable mapping of requesteddependencies.- Specified by:
getRequestedDependenciesin interfaceProjectDescription- Returns:
- the requested dependencies
-
getGroupId
Description copied from interface:ProjectDescriptionReturn the buildgroupId.- Specified by:
getGroupIdin interfaceProjectDescription- Returns:
- the groupId or
null
-
setGroupId
-
getArtifactId
Description copied from interface:ProjectDescriptionReturn the buildartifactId.- Specified by:
getArtifactIdin interfaceProjectDescription- Returns:
- the artifactId or
null
-
setArtifactId
-
getVersion
Description copied from interface:ProjectDescriptionReturn the version of the project.- Specified by:
getVersionin interfaceProjectDescription- Returns:
- the version of
null
-
setVersion
-
getName
Description copied from interface:ProjectDescriptionReturn a simple name for the project.- Specified by:
getNamein interfaceProjectDescription- Returns:
- the name of the project or
null
-
setName
-
getDescription
Description copied from interface:ProjectDescriptionReturn a human readable description of the project.- Specified by:
getDescriptionin interfaceProjectDescription- Returns:
- the description of the project or
null
-
setDescription
-
getApplicationName
Description copied from interface:ProjectDescriptionReturn the name of the application as a standard Java identifier.- Specified by:
getApplicationNamein interfaceProjectDescription- Returns:
- the name of the application or
null
-
setApplicationName
-
getPackageName
Description copied from interface:ProjectDescriptionReturn the root package name of the project.- Specified by:
getPackageNamein interfaceProjectDescription- Returns:
- the package name or
null
-
setPackageName
-
getBaseDirectory
Description copied from interface:ProjectDescriptionReturn the base directory of the project ornullto use the root directory.- Specified by:
getBaseDirectoryin interfaceProjectDescription- Returns:
- the base directory
-
setBaseDirectory
-