Interface IBuildArtifactEngineer
- All Known Implementing Classes:
AbstractNonMavenBuildArtifactEngineer
IBuildArtifact
engineer.
Should not access any services in the platform, just use components provided by
IBuildArtifactEngineer.IEngineeringContext
.
- Version:
- $Revision$ $Date$
- Author:
- Stepan Roh, Polarion Software
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
Components and methods necessary for all engineering work. -
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Amend (fill in the gaps of) build artifact.createPOMFile
(IBuildArtifactEngineer.IEngineeringContext context, String buildDescriptorName, String calculationDescriptorName, File localDir) Create POM (Project Object Model from Maven 2) file (pom.xml) for given artifact.deriveMavenGoals
(IBuildArtifactEngineer.IEngineeringContext context, String buildName) Derive phases/goals to run during build described by build descriptor of given name.expandDerivedBuildDeploymentDefinition
(IBuildArtifactEngineer.IEngineeringContext context, IBuildDescriptor.IDerivedBuildDeploymentDefinition derivedDef) Will transformIBuildDescriptor.IDerivedBuildDeploymentDefinition
toIBuildDescriptor.ISimpleBuildDeploymentDefinition
(if possible).
-
Field Details
-
ATTACHED_VALUE_LOCAL_POM
build artifact's attached value: localpom.xml
File
- See Also:
-
-
Method Details
-
amendBuildArtifact
void amendBuildArtifact(IBuildArtifactEngineer.IEngineeringContext context) throws GenericBuilderException Amend (fill in the gaps of) build artifact.Note that when
tag
is specified in prepared artifact all operations inISourceRepository
must be done with tagged locations.- Parameters:
context
- engineering context- Throws:
IllegalArgumentException
- if context isnull
GenericBuilderException
- if error happens
-
createPOMFile
File createPOMFile(IBuildArtifactEngineer.IEngineeringContext context, String buildDescriptorName, String calculationDescriptorName, File localDir) throws GenericBuilderException Create POM (Project Object Model from Maven 2) file (pom.xml) for given artifact.If given artifact already has POM (by nature, not that it seems to exists there), its location is returned and no changes are done.
Passing of build/calculation descriptor name allows to create POM based on build/calculation configuration (needed for some).
Local directory points to the directory corresponding to artifact's repository object's location.
Created POM must be constructed in such a way that if invoked it will auto-invoke POM's of contained artifacts (or it will do the same work as if invoked).
Will set build artifact's attached value
ATTACHED_VALUE_LOCAL_POM
to returnedFile
.- Parameters:
context
- engineering contextbuildDescriptorName
- build descriptor name ornull
calculationDescriptorName
- calculation descriptor name ornull
localDir
- local directory- Returns:
- POM file location
- Throws:
IllegalArgumentException
- if context isnull
IllegalArgumentException
- if localDir isnull
GenericBuilderException
- if error happens
-
deriveMavenGoals
Derive phases/goals to run during build described by build descriptor of given name.- Parameters:
context
- engineering contextbuildName
- build descriptor name- Returns:
List
ofString
phase/goal names ornull
if not specified- Throws:
IllegalArgumentException
- if context isnull
IllegalArgumentException
- if buildName isnull
-
expandDerivedBuildDeploymentDefinition
Collection expandDerivedBuildDeploymentDefinition(IBuildArtifactEngineer.IEngineeringContext context, IBuildDescriptor.IDerivedBuildDeploymentDefinition derivedDef) Will transformIBuildDescriptor.IDerivedBuildDeploymentDefinition
toIBuildDescriptor.ISimpleBuildDeploymentDefinition
(if possible).Unknown derived build deployment artifact name must be ignored.
- Parameters:
context
- engineering contextderivedDef
-- Returns:
Collection
ofIBuildDescriptor.ISimpleBuildDeploymentDefinition
s (notnull
)- Throws:
IllegalArgumentException
- if context isnull
-