org.apache.maven.model.v3_0_0
Class Model

java.lang.Object
  extended by org.apache.maven.model.v3_0_0.ModelBase
      extended by org.apache.maven.model.v3_0_0.Model
All Implemented Interfaces:
Serializable

public class Model
extends ModelBase
implements Serializable

The <project> element is the root of the descriptor. The following table lists all of the possible child elements.

Version:
$Revision$ $Date$
See Also:
Serialized Form

Constructor Summary
Model()
           
 
Method Summary
 void addBranch(Branch branch)
          Method addBranch.
 void addContributor(Contributor contributor)
          Method addContributor.
 void addDeveloper(Developer developer)
          Method addDeveloper.
 void addLicense(License license)
          Method addLicense.
 void addMailingList(MailingList mailingList)
          Method addMailingList.
 void addPackageGroup(PackageGroup packageGroup)
          Method addPackageGroup.
 void addProperty(String key, String value)
          Method addProperty.
 void addReport(String string)
          Method addReport.
 void addVersion(Version version)
          Method addVersion.
 String getArtifactId()
          Get the identifier for this artifact that is unique within the group given by the group ID.
 List<Branch> getBranches()
          Method getBranches.
 Build getBuild()
          Get information required to build the project.
 List<Contributor> getContributors()
          Method getContributors.
 String getCurrentVersion()
          Get the current version of the artifact produced by this project.
 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<Developer> getDevelopers()
          Method getDevelopers.
 String getDistributionDirectory()
          Get the directory on the web server where the final distributions will be published.
 String getDistributionSite()
          Get the server where the final distributions will be published.
 String getExtend()
          Get the location of the parent project, if one exists.
 String getGroupId()
          Get a universally unique identifier for a project.
 String getGumpRepositoryId()
          Get this is the repository identifier in Gump that this project is part of.
 String getId()
          Get Deprecated.
 String getInceptionYear()
          Get the year of the project's inception, specified with 4 digits.
 String getIssueTrackingUrl()
          Get the URL of the project's issue tracking system.
 List<License> getLicenses()
          Method getLicenses.
 String getLogo()
          Get the URL of the project's logo image.
 List<MailingList> getMailingLists()
          Method getMailingLists.
 String getModelEncoding()
          Get the modelEncoding field.
 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 getPackage()
           
 List<PackageGroup> getPackageGroups()
          Method getPackageGroups.
 String getPackageName()
          Get the Java package name of the project.
 String getPomVersion()
          Get declares to which version of project descriptor this POM conforms.
 Properties getProperties()
          Method getProperties.
 List<String> getReports()
          Method getReports.
 Repository getRepository()
          Get specification for the SCM used by the project, such as CVS, Subversion, etc.
 String getShortDescription()
          Get a short description of the project.
 String getSiteAddress()
          Get the hostname of the web server that hosts the project's web site.
 String getSiteDirectory()
          Get the directory on the web server where the public web site for this project resides.
 String getUrl()
          Get the URL to the project's homepage.
 String getVersion()
           
 List<Version> getVersions()
          Method getVersions.
 void removeBranch(Branch branch)
          Method removeBranch.
 void removeContributor(Contributor contributor)
          Method removeContributor.
 void removeDeveloper(Developer developer)
          Method removeDeveloper.
 void removeLicense(License license)
          Method removeLicense.
 void removeMailingList(MailingList mailingList)
          Method removeMailingList.
 void removePackageGroup(PackageGroup packageGroup)
          Method removePackageGroup.
 void removeReport(String string)
          Method removeReport.
 void removeVersion(Version version)
          Method removeVersion.
 void setArtifactId(String artifactId)
          Set the identifier for this artifact that is unique within the group given by the group ID.
 void setBranches(List<Branch> branches)
          Set contains information on SCM branches of the project.
 void setBuild(Build build)
          Set information required to build the project.
 void setContributors(List<Contributor> contributors)
          Set describes the contributors to a project that are not yet committers.
 void setCurrentVersion(String currentVersion)
          Set the current version of the artifact produced by this project.
 void setDescription(String description)
          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<Developer> developers)
          Set describes the committers of a project.
 void setDistributionDirectory(String distributionDirectory)
          Set the directory on the web server where the final distributions will be published.
 void setDistributionSite(String distributionSite)
          Set the server where the final distributions will be published.
 void setExtend(String extend)
          Set the location of the parent project, if one exists.
 void setGroupId(String groupId)
          Set a universally unique identifier for a project.
 void setGumpRepositoryId(String gumpRepositoryId)
          Set this is the repository identifier in Gump that this project is part of.
 void setId(String id)
          Set Deprecated.
 void setInceptionYear(String inceptionYear)
          Set the year of the project's inception, specified with 4 digits.
 void setIssueTrackingUrl(String issueTrackingUrl)
          Set the URL of the project's issue tracking system.
 void setLicenses(List<License> licenses)
          Set this element describes all of the licenses for this project.
 void setLogo(String logo)
          Set the URL of the project's logo image.
 void setMailingLists(List<MailingList> mailingLists)
          Set contains information about a project's mailing lists.
 void setModelEncoding(String modelEncoding)
          Set the modelEncoding field.
 void setName(String name)
          Set the full name of the project.
 void setOrganization(Organization organization)
          Set this element describes various attributes of the organization to which the project belongs.
 void setPackage(String packageName)
           
 void setPackageGroups(List<PackageGroup> packageGroups)
          Set package groups required for complete javadocs.
 void setPackageName(String packageName)
          Set the Java package name of the project.
 void setPomVersion(String pomVersion)
          Set declares to which version of project descriptor this POM conforms.
 void setProperties(Properties properties)
          Set project properties that will be used by various plugins.
 void setReports(List<String> reports)
          Set this element includes the specification of reports to be included in a Maven-generated site.
 void setRepository(Repository repository)
          Set specification for the SCM used by the project, such as CVS, Subversion, etc.
 void setShortDescription(String shortDescription)
          Set a short description of the project.
 void setSiteAddress(String siteAddress)
          Set the hostname of the web server that hosts the project's web site.
 void setSiteDirectory(String siteDirectory)
          Set the directory on the web server where the public web site for this project resides.
 void setUrl(String url)
          Set the URL to the project's homepage.
 void setVersion(String version)
           
 void setVersions(List<Version> versions)
          Set contains information on previous versions of the project.
 
Methods inherited from class org.apache.maven.model.v3_0_0.ModelBase
addDependency, getDependencies, removeDependency, setDependencies
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Model

public Model()
Method Detail

addBranch

public void addBranch(Branch branch)
Method addBranch.

Parameters:
branch -

addContributor

public void addContributor(Contributor contributor)
Method addContributor.

Parameters:
contributor -

addDeveloper

public void addDeveloper(Developer developer)
Method addDeveloper.

Parameters:
developer -

addLicense

public void addLicense(License license)
Method addLicense.

Parameters:
license -

addMailingList

public void addMailingList(MailingList mailingList)
Method addMailingList.

Parameters:
mailingList -

addPackageGroup

public void addPackageGroup(PackageGroup packageGroup)
Method addPackageGroup.

Parameters:
packageGroup -

addProperty

public void addProperty(String key,
                        String value)
Method addProperty.

Parameters:
key -
value -

addReport

public void addReport(String string)
Method addReport.

Parameters:
string -

addVersion

public void addVersion(Version version)
Method addVersion.

Parameters:
version -

getArtifactId

public String getArtifactId()
Get the identifier for this artifact that is unique within the group given by the group ID. An artifact is something that is either produced or used by a project. Examples of artifacts produced by Maven for a project include: JARs, source and binary distributions, and WARs.

Returns:
String

getBranches

public List<Branch> getBranches()
Method getBranches.

Returns:
List

getBuild

public Build getBuild()
Get information required to build the project.

Returns:
Build

getContributors

public List<Contributor> getContributors()
Method getContributors.

Returns:
List

getCurrentVersion

public String getCurrentVersion()
Get the current version of the artifact produced by this project.

Returns:
String

getDescription

public 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. While this element can be specified as CDATA to enable the use of HTML tags within the description, it is discouraged to allow plain text representation. If you need to modify the index page of the generated web site, you are able to specify your own instead of adjusting this text.

Returns:
String

getDevelopers

public List<Developer> getDevelopers()
Method getDevelopers.

Returns:
List

getDistributionDirectory

public String getDistributionDirectory()
Get the directory on the web server where the final distributions will be published. This is used when the distributions are deployed.

Returns:
String

getDistributionSite

public String getDistributionSite()
Get the server where the final distributions will be published. This is used when the distributions are deployed. If this isn't defined, the central repository is used instead as determined by maven.repo.central and maven.repo.central.directory.

Returns:
String

getExtend

public String getExtend()
Get the location of the parent project, if one exists. Values from the parent project will be the default for this project if they are left unspecified. The path may be absolute, or relative to the current project.xml file. For example, <extend>${basedir}/../project.xml</extend>.

Returns:
String

getGroupId

public String getGroupId()
Get a universally unique identifier for a project. It is normal to use a fully-qualified package name to distinguish it from other projects with a similar name (eg. org.apache.maven).

Returns:
String

getGumpRepositoryId

public String getGumpRepositoryId()
Get this is the repository identifier in Gump that this project is part of.

Returns:
String

getId

public String getId()
Get Deprecated. When used, this sets both the groupId and artifactId elements if they were previously empty.

Returns:
String

getInceptionYear

public String getInceptionYear()
Get the year of the project's inception, specified with 4 digits. This value is used when generating copyright notices as well as being informational.

Returns:
String

getIssueTrackingUrl

public String getIssueTrackingUrl()
Get the URL of the project's issue tracking system.

Returns:
String

getLicenses

public List<License> getLicenses()
Method getLicenses.

Returns:
List

getLogo

public String getLogo()
Get the URL of the project's logo image. This can be an URL relative to the base directory of the generated web site, (e.g., /images/project-logo.png) or an absolute URL (e.g., http://my.corp/project-logo.png). This is used when generating the project documentation.

Returns:
String

getMailingLists

public List<MailingList> getMailingLists()
Method getMailingLists.

Returns:
List

getModelEncoding

public String getModelEncoding()
Get the modelEncoding field.

Returns:
String

getName

public String getName()
Get the full name of the project.

Returns:
String

getOrganization

public Organization getOrganization()
Get this element describes various attributes of the organization to which the project belongs. These attributes are utilized when documentation is created (for copyright notices and links).

Returns:
Organization

getPackageGroups

public List<PackageGroup> getPackageGroups()
Method getPackageGroups.

Returns:
List

getPackageName

public String getPackageName()
Get the Java package name of the project. This value is used when generating JavaDoc.

Returns:
String

getPomVersion

public String getPomVersion()
Get declares to which version of project descriptor this POM conforms. The only valid value is 3.

Returns:
String

getProperties

public Properties getProperties()
Method getProperties.

Returns:
Properties

getReports

public List<String> getReports()
Method getReports.

Returns:
List

getRepository

public Repository getRepository()
Get specification for the SCM used by the project, such as CVS, Subversion, etc.

Returns:
Repository

getShortDescription

public String getShortDescription()
Get a short description of the project. The short description should be limited to a single line.

Returns:
String

getSiteAddress

public String getSiteAddress()
Get the hostname of the web server that hosts the project's web site. This is used when the web site is deployed.

Returns:
String

getSiteDirectory

public String getSiteDirectory()
Get the directory on the web server where the public web site for this project resides. This is used when the web site is deployed.

Returns:
String

getUrl

public String getUrl()
Get the URL to the project's homepage.

Returns:
String

getVersions

public List<Version> getVersions()
Method getVersions.

Returns:
List

removeBranch

public void removeBranch(Branch branch)
Method removeBranch.

Parameters:
branch -

removeContributor

public void removeContributor(Contributor contributor)
Method removeContributor.

Parameters:
contributor -

removeDeveloper

public void removeDeveloper(Developer developer)
Method removeDeveloper.

Parameters:
developer -

removeLicense

public void removeLicense(License license)
Method removeLicense.

Parameters:
license -

removeMailingList

public void removeMailingList(MailingList mailingList)
Method removeMailingList.

Parameters:
mailingList -

removePackageGroup

public void removePackageGroup(PackageGroup packageGroup)
Method removePackageGroup.

Parameters:
packageGroup -

removeReport

public void removeReport(String string)
Method removeReport.

Parameters:
string -

removeVersion

public void removeVersion(Version version)
Method removeVersion.

Parameters:
version -

setArtifactId

public void setArtifactId(String artifactId)
Set the identifier for this artifact that is unique within the group given by the group ID. An artifact is something that is either produced or used by a project. Examples of artifacts produced by Maven for a project include: JARs, source and binary distributions, and WARs.

Parameters:
artifactId -

setBranches

public void setBranches(List<Branch> branches)
Set contains information on SCM branches of the project.

Parameters:
branches -

setBuild

public void setBuild(Build build)
Set information required to build the project.

Parameters:
build -

setContributors

public void setContributors(List<Contributor> contributors)
Set describes the contributors to a project that are not yet committers.

Parameters:
contributors -

setCurrentVersion

public void setCurrentVersion(String currentVersion)
Set the current version of the artifact produced by this project.

Parameters:
currentVersion -

setDescription

public void setDescription(String description)
Set a detailed description of the project, used by Maven whenever it needs to describe the project, such as on the web site. While this element can be specified as CDATA to enable the use of HTML tags within the description, it is discouraged to allow plain text representation. If you need to modify the index page of the generated web site, you are able to specify your own instead of adjusting this text.

Parameters:
description -

setDevelopers

public void setDevelopers(List<Developer> developers)
Set describes the committers of a project.

Parameters:
developers -

setDistributionDirectory

public void setDistributionDirectory(String distributionDirectory)
Set the directory on the web server where the final distributions will be published. This is used when the distributions are deployed.

Parameters:
distributionDirectory -

setDistributionSite

public void setDistributionSite(String distributionSite)
Set the server where the final distributions will be published. This is used when the distributions are deployed. If this isn't defined, the central repository is used instead as determined by maven.repo.central and maven.repo.central.directory.

Parameters:
distributionSite -

setExtend

public void setExtend(String extend)
Set the location of the parent project, if one exists. Values from the parent project will be the default for this project if they are left unspecified. The path may be absolute, or relative to the current project.xml file. For example, <extend>${basedir}/../project.xml</extend>.

Parameters:
extend -

setGroupId

public void setGroupId(String groupId)
Set a universally unique identifier for a project. It is normal to use a fully-qualified package name to distinguish it from other projects with a similar name (eg. org.apache.maven).

Parameters:
groupId -

setGumpRepositoryId

public void setGumpRepositoryId(String gumpRepositoryId)
Set this is the repository identifier in Gump that this project is part of.

Parameters:
gumpRepositoryId -

setId

public void setId(String id)
Set Deprecated. When used, this sets both the groupId and artifactId elements if they were previously empty.

Parameters:
id -

setInceptionYear

public void setInceptionYear(String inceptionYear)
Set the year of the project's inception, specified with 4 digits. This value is used when generating copyright notices as well as being informational.

Parameters:
inceptionYear -

setIssueTrackingUrl

public void setIssueTrackingUrl(String issueTrackingUrl)
Set the URL of the project's issue tracking system.

Parameters:
issueTrackingUrl -

setLicenses

public void setLicenses(List<License> licenses)
Set this element describes all of the licenses for this project. Each license is described by a 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.

Parameters:
licenses -

setLogo

public void setLogo(String logo)
Set the URL of the project's logo image. This can be an URL relative to the base directory of the generated web site, (e.g., /images/project-logo.png) or an absolute URL (e.g., http://my.corp/project-logo.png). This is used when generating the project documentation.

Parameters:
logo -

setMailingLists

public void setMailingLists(List<MailingList> mailingLists)
Set contains information about a project's mailing lists.

Parameters:
mailingLists -

setModelEncoding

public void setModelEncoding(String modelEncoding)
Set the modelEncoding field.

Parameters:
modelEncoding -

setName

public void setName(String name)
Set the full name of the project.

Parameters:
name -

setOrganization

public void setOrganization(Organization organization)
Set this element describes various attributes of the organization to which the project belongs. These attributes are utilized when documentation is created (for copyright notices and links).

Parameters:
organization -

setPackageGroups

public void setPackageGroups(List<PackageGroup> packageGroups)
Set package groups required for complete javadocs.

Parameters:
packageGroups -

setPackageName

public void setPackageName(String packageName)
Set the Java package name of the project. This value is used when generating JavaDoc.

Parameters:
packageName -

setPomVersion

public void setPomVersion(String pomVersion)
Set declares to which version of project descriptor this POM conforms. The only valid value is 3.

Parameters:
pomVersion -

setProperties

public void setProperties(Properties properties)
Set project properties that will be used by various plugins. The format is <name>value</name>.

Parameters:
properties -

setReports

public void setReports(List<String> reports)
Set this element includes the specification of reports to be included in a Maven-generated site. These reports will be run when a user executes maven site. All of the reports will be included in the navigation bar for browsing in the order they are specified.

Parameters:
reports -

setRepository

public void setRepository(Repository repository)
Set specification for the SCM used by the project, such as CVS, Subversion, etc.

Parameters:
repository -

setShortDescription

public void setShortDescription(String shortDescription)
Set a short description of the project. The short description should be limited to a single line.

Parameters:
shortDescription -

setSiteAddress

public void setSiteAddress(String siteAddress)
Set the hostname of the web server that hosts the project's web site. This is used when the web site is deployed.

Parameters:
siteAddress -

setSiteDirectory

public void setSiteDirectory(String siteDirectory)
Set the directory on the web server where the public web site for this project resides. This is used when the web site is deployed.

Parameters:
siteDirectory -

setUrl

public void setUrl(String url)
Set the URL to the project's homepage.

Parameters:
url -

setVersions

public void setVersions(List<Version> versions)
Set contains information on previous versions of the project.

Parameters:
versions -

setVersion

public void setVersion(String version)

getVersion

public String getVersion()

setPackage

public void setPackage(String packageName)

getPackage

public String getPackage()


Copyright © 2001-2011 Apache Software Foundation. All Rights Reserved.