org.apache.maven.werkz.jelly
Class UseGoalsTag

java.lang.Object
  extended byorg.apache.commons.jelly.TagSupport
      extended byorg.apache.maven.werkz.jelly.WerkzTagSupport
          extended byorg.apache.maven.werkz.jelly.UseGoalsTag
All Implemented Interfaces:
Tag

public class UseGoalsTag
extends WerkzTagSupport

This tag outputs a sorted Map of Maps all of the goals, indexed by their prefix and their goal name. This is output to a variable. This map of maps makes it easy to navigate the available Goals.

So if the goals is output to a variable called 'g' then you can access a specific goal via a Jexl expression ${g.java.compile} or to find all the 'java' goals you can use ${g.java} which returns a sorted Map.

Version:
$Revision: 1.2 $
Author:
James Strachan

Field Summary
 
Fields inherited from class org.apache.commons.jelly.TagSupport
body, context, hasTrimmed, parent, shouldTrim
 
Constructor Summary
UseGoalsTag()
           
 
Method Summary
protected  java.util.Map createMap()
          Factory method to create a new sorted map
 void doTag(XMLOutput output)
          Evaluate the body to register all the various goals and pre/post conditions then run all the current targets
 void setVar(java.lang.String var)
          Sets the variable for which the Map of Map of goals will be exported
 
Methods inherited from class org.apache.maven.werkz.jelly.WerkzTagSupport
getGoal, getProject
 
Methods inherited from class org.apache.commons.jelly.TagSupport
findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, getBody, getBodyText, getBodyText, getContext, getParent, invokeBody, isEscapeText, isTrim, setBody, setContext, setEscapeText, setParent, setTrim, trimBody
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UseGoalsTag

public UseGoalsTag()
Method Detail

doTag

public void doTag(XMLOutput output)
           throws JellyTagException
Evaluate the body to register all the various goals and pre/post conditions then run all the current targets

Throws:
JellyTagException

setVar

public void setVar(java.lang.String var)
Sets the variable for which the Map of Map of goals will be exported


createMap

protected java.util.Map createMap()
Factory method to create a new sorted map



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