public class Model extends ModelBaseimplements Serializable , Cloneable
<project> element is the root of the descriptor. The following table lists all of the possible child elements.
| Constructor and Description |
|---|
Model()
|
| Modifier and Type | Method and Description |
|---|---|
void |
addContributor(Contributor
Method addContributor.
|
void |
addDeveloper(Developer
Method addDeveloper.
|
void |
addLicense(License
Method addLicense.
|
void |
addMailingList(MailingList
Method addMailingList.
|
void |
addProfile(Profile
Method addProfile.
|
Model |
clone()
Method clone.
|
String |
getArtifactId()
Get the identifier for this artifact that is unique within the group given by the group ID.
|
Build |
getBuild()
Get information required to build the project.
|
CiManagement |
getCiManagement()
Get the project's continuous integration information.
|
List |
getContributors()
Method getContributors.
|
String |
getDescription()
Get a detailed description of the project, used by Maven whenever it needs to describe the project, such as on the web site.
|
List |
getDevelopers()
Method getDevelopers.
|
String |
getGroupId()
Get a universally unique identifier for a project.
|
String |
getId()
|
String |
getInceptionYear()
Get the year of the project's inception, specified with 4 digits.
|
IssueManagement |
getIssueManagement()
Get the project's issue management system information.
|
List |
getLicenses()
Method getLicenses.
|
List |
getMailingLists()
Method getMailingLists.
|
String |
getModelEncoding()
Get the modelEncoding field.
|
String |
getModelVersion()
Get declares to which version of project descriptor this POM conforms.
|
String |
getName()
Get the full name of the project.
|
Organization |
getOrganization()
Get this element describes various attributes of the organization to which the project belongs.
|
String |
getPackaging()
Get the type of artifact this project produces, for example
jar
war
ear
pom.
|
Parent |
getParent()
Get the location of the parent project, if one exists.
|
File |
getPomFile()
Gets the POM file for the corresponding project (if any).
|
Prerequisites |
getPrerequisites()
Get describes the prerequisites in the build environment for this project.
|
List |
getProfiles()
Method getProfiles.
|
File |
getProjectDirectory()
Gets the base directory for the corresponding project (if any).
|
Scm |
getScm()
Get specification for the SCM used by the project, such as CVS, Subversion, etc.
|
String |
getUrl()
Get the URL to the project's homepage.
|
String |
getVersion()
Get the current version of the artifact produced by this project.
|
void |
removeContributor(Contributor
Method removeContributor.
|
void |
removeDeveloper(Developer
Method removeDeveloper.
|
void |
removeLicense(License
Method removeLicense.
|
void |
removeMailingList(MailingList
Method removeMailingList.
|
void |
removeProfile(Profile
Method removeProfile.
|
void |
setArtifactId(String
Set the identifier for this artifact that is unique within the group given by the group ID.
|
void |
setBuild(Build
Set information required to build the project.
|
void |
setCiManagement(CiManagement
Set the project's continuous integration information.
|
void |
setContributors(List
Set describes the contributors to a project that are not yet committers.
|
void |
setDescription(String
Set a detailed description of the project, used by Maven whenever it needs to describe the project, such as on the web site.
|
void |
setDevelopers(List
Set describes the committers of a project.
|
void |
setGroupId(String
Set a universally unique identifier for a project.
|
void |
setInceptionYear(String
Set the year of the project's inception, specified with 4 digits.
|
void |
setIssueManagement(IssueManagement
Set the project's issue management system information.
|
void |
setLicenses(List
Set this element describes all of the licenses for this project.
|
void |
setMailingLists(List
Set contains information about a project's mailing lists.
|
void |
setModelEncoding(String
Set the modelEncoding field.
|
void |
setModelVersion(String
Set declares to which version of project descriptor this POM conforms.
|
void |
setName(String
Set the full name of the project.
|
void |
setOrganization(Organization
Set this element describes various attributes of the organization to which the project belongs.
|
void |
setPackaging(String
Set the type of artifact this project produces, for example
jar
war
ear
pom.
|
void |
setParent(Parent
Set the location of the parent project, if one exists.
|
void |
setPomFile(File
|
void |
setPrerequisites(Prerequisites
Set describes the prerequisites in the build environment for this project.
|
void |
setProfiles(List
Set a listing of project-local build profiles which will modify the build process when activated.
|
void |
setScm(Scm
Set specification for the SCM used by the project, such as CVS, Subversion, etc.
|
void |
setUrl(String
Set the URL to the project's homepage.
|
void |
setVersion(String
Set the current version of the artifact produced by this project.
|
String |
toString()
|
addDependency, addModule, addPluginRepository, addProperty, addRepository, getDependencies, getDependencyManagement, getDistributionManagement, getLocation, getModules, getPluginRepositories, getProperties, getReporting, getReports, getRepositories, removeDependency, removeModule, removePluginRepository, removeRepository, setDependencies, setDependencyManagement, setDistributionManagement, setLocation, setModules, setPluginRepositories, setProperties, setReporting, setReports, setRepositoriespublic void addContributor(Contributorcontributor)
contributor -
public void addDeveloper(Developerdeveloper)
developer -
public void addLicense(Licenselicense)
license -
public void addMailingList(MailingListmailingList)
mailingList -
public void addProfile(Profileprofile)
profile -
public StringgetArtifactId()
public BuildgetBuild()
public CiManagementgetCiManagement()
public List<Contributor > getContributors()
public StringgetDescription()
public StringgetGroupId()
org.apache.maven).
public StringgetInceptionYear()
public IssueManagementgetIssueManagement()
public List<MailingList > getMailingLists()
public StringgetModelEncoding()
public StringgetModelVersion()
public StringgetName()
public OrganizationgetOrganization()
public StringgetPackaging()
jar
war
ear
pom. Plugins can create their own packaging, and therefore their own packaging types, so this list does not contain all possible types.
public ParentgetParent()
public PrerequisitesgetPrerequisites()
public ScmgetScm()
public StringgetUrl()
public StringgetVersion()
public void removeContributor(Contributorcontributor)
contributor -
public void removeDeveloper(Developerdeveloper)
developer -
public void removeLicense(Licenselicense)
license -
public void removeMailingList(MailingListmailingList)
mailingList -
public void removeProfile(Profileprofile)
profile -
public void setArtifactId(StringartifactId)
artifactId -
public void setBuild(Buildbuild)
build -
public void setCiManagement(CiManagementciManagement)
ciManagement -
public void setContributors(List<Contributor > contributors)
contributors -
public void setDescription(Stringdescription)
description -
public void setDevelopers(List<Developer > developers)
developers -
public void setGroupId(StringgroupId)
org.apache.maven).
groupId -
public void setInceptionYear(StringinceptionYear)
inceptionYear -
public void setIssueManagement(IssueManagementissueManagement)
issueManagement -
public void setLicenses(List<License > licenses)
license element, which is then described by additional elements. Projects should only list the license(s) that applies to the project and not the licenses that apply to dependencies. If multiple licenses are listed, it is assumed that the user can select any of them, not that they must accept all.
licenses -
public void setMailingLists(List<MailingList > mailingLists)
mailingLists -
public void setModelEncoding(StringmodelEncoding)
modelEncoding -
public void setModelVersion(StringmodelVersion)
modelVersion -
public void setName(Stringname)
name -
public void setOrganization(Organizationorganization)
organization -
public void setPackaging(Stringpackaging)
jar
war
ear
pom. Plugins can create their own packaging, and therefore their own packaging types, so this list does not contain all possible types.
packaging -
public void setParent(Parentparent)
parent -
public void setPrerequisites(Prerequisitesprerequisites)
prerequisites -
public void setProfiles(List<Profile > profiles)
profiles -
public void setScm(Scmscm)
scm -
public void setUrl(Stringurl)
url -
public void setVersion(Stringversion)
version -
public FilegetPomFile()
null if this model does not belong to a local project (e.g. describes the metadata of some artifact from the repository).
public void setPomFile(FilepomFile)
public FilegetProjectDirectory()
null if this model does not belong to a local project (e.g. describes the metadata of some artifact from the repository).
public StringgetId()
groupId:artifactId:packaging:version
public StringtoString()