org.apache.maven.plugin
Class GoalToJellyScriptHousingMapper

java.lang.Object
  extended byorg.apache.maven.plugin.GoalToJellyScriptHousingMapper
All Implemented Interfaces:
PluginDefinitionHandler

public class GoalToJellyScriptHousingMapper
extends java.lang.Object
implements PluginDefinitionHandler

This is the process that we use: - Start with goal X - Gather prereqs for X We want to find all goals that will be executed due to X being executed we don't care about ordering here because when werkz executes it will sort that out for us. We just need to make sure all the appropriate plugins have been loaded so that werkz can find the goals it needs. For a single goal we will collect the set of goals that will be executed with it.


Constructor Summary
GoalToJellyScriptHousingMapper()
          Default constructor.
 
Method Summary
 void addDynaTagLib(java.lang.String tagLibUri, JellyScriptHousing jellyScriptHousing)
           
 void addGoal(java.lang.String name, java.lang.String prereqs, java.lang.String description, JellyScriptHousing jellyScriptHousing)
           
 void addPluginDynaTagDep(JellyScriptHousing housing, java.lang.String uri)
           
 void addPostGoal(java.lang.String name, JellyScriptHousing jellyScriptHousing)
           
 void addPreGoal(java.lang.String name, JellyScriptHousing jellyScriptHousing)
           
(package private)  void addResolvedPlugins(java.util.List projectHousings)
           
(package private)  void clearResolvedPlugins()
           
 java.lang.String getDefaultGoalName()
           
 Goal[] getExecutionChain(java.lang.String name, WerkzProject project)
           
(package private)  java.lang.String getGoalDescription(java.lang.String goalName)
           
(package private)  java.util.Set getGoalNames()
           
 JellyScriptHousing getPluginHousing(java.lang.String goal)
           
(package private)  java.util.HashSet getPostGoalDecorators(java.lang.String goalName)
           
(package private)  java.util.HashSet getPreGoalDecorators(java.lang.String goalName)
           
(package private)  void invalidatePlugin(JellyScriptHousing housing)
           
(package private)  void merge(GoalToJellyScriptHousingMapper mapper)
          Merge parent mapper.
 void removePluginDynaTagDep(JellyScriptHousing housing, java.lang.String uri)
           
(package private)  java.util.Set resolveJellyScriptHousings(java.lang.String goal)
          Find the appropriate plugins that provide the give goal and its precursors.
 void setDefaultGoalName(java.lang.String defaultGoalName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GoalToJellyScriptHousingMapper

public GoalToJellyScriptHousingMapper()
Default constructor.

Method Detail

merge

void merge(GoalToJellyScriptHousingMapper mapper)
     throws CyclicGoalChainException
Merge parent mapper. Used to setup a transient submapper.

Parameters:
mapper - mapper to copy from
Throws:
CyclicGoalChainException
To Do:
figure out which are actually needed, change redundant initialisers by removing here, or adding others to default constructor (eg goalProject init), We should have a way to inherit entire werkz project instead of hokey goal copying

getDefaultGoalName

public java.lang.String getDefaultGoalName()

setDefaultGoalName

public void setDefaultGoalName(java.lang.String defaultGoalName)
Specified by:
setDefaultGoalName in interface PluginDefinitionHandler

getPluginHousing

public JellyScriptHousing getPluginHousing(java.lang.String goal)

getPostGoalDecorators

java.util.HashSet getPostGoalDecorators(java.lang.String goalName)

getPreGoalDecorators

java.util.HashSet getPreGoalDecorators(java.lang.String goalName)

resolveJellyScriptHousings

java.util.Set resolveJellyScriptHousings(java.lang.String goal)
                                   throws NoSuchGoalException
Find the appropriate plugins that provide the give goal and its precursors. Goals such as ${report}:register will need to be resolved lazily.

Parameters:
goal - the goal to find
Returns:
the set of plugins
Throws:
NoSuchGoalException - if the given goal is in no plugins
See Also:
MavenAttainGoalTag

getExecutionChain

public Goal[] getExecutionChain(java.lang.String name,
                                WerkzProject project)
                         throws NoSuchGoalException
Throws:
NoSuchGoalException
To Do:
[1.0] use werkz beta-11 version instead

addPluginDynaTagDep

public void addPluginDynaTagDep(JellyScriptHousing housing,
                                java.lang.String uri)
Specified by:
addPluginDynaTagDep in interface PluginDefinitionHandler

removePluginDynaTagDep

public void removePluginDynaTagDep(JellyScriptHousing housing,
                                   java.lang.String uri)
Specified by:
removePluginDynaTagDep in interface PluginDefinitionHandler

addDynaTagLib

public void addDynaTagLib(java.lang.String tagLibUri,
                          JellyScriptHousing jellyScriptHousing)
Specified by:
addDynaTagLib in interface PluginDefinitionHandler

addPostGoal

public void addPostGoal(java.lang.String name,
                        JellyScriptHousing jellyScriptHousing)
Specified by:
addPostGoal in interface PluginDefinitionHandler

addPreGoal

public void addPreGoal(java.lang.String name,
                       JellyScriptHousing jellyScriptHousing)
Specified by:
addPreGoal in interface PluginDefinitionHandler

addGoal

public void addGoal(java.lang.String name,
                    java.lang.String prereqs,
                    java.lang.String description,
                    JellyScriptHousing jellyScriptHousing)
Specified by:
addGoal in interface PluginDefinitionHandler

getGoalNames

java.util.Set getGoalNames()
Returns:
goal names

getGoalDescription

java.lang.String getGoalDescription(java.lang.String goalName)

addResolvedPlugins

void addResolvedPlugins(java.util.List projectHousings)

clearResolvedPlugins

void clearResolvedPlugins()

invalidatePlugin

void invalidatePlugin(JellyScriptHousing housing)


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