org.apache.maven.jelly.tags.maven
Class MavenTag

java.lang.Object
  extended byorg.apache.commons.jelly.TagSupport
      extended byorg.apache.maven.jelly.tags.BaseTagSupport
          extended byorg.apache.maven.jelly.tags.maven.MavenTag
All Implemented Interfaces:
Tag
Direct Known Subclasses:
ConcatTag, InputTag, ReactorTag

public class MavenTag
extends BaseTagSupport

A way of running maven as a Jelly tag

Version:
$Id: MavenTag.java 517014 2007-03-11 21:15:50Z ltheussl $
Author:
bob mcwhirter, Jason van Zyl
To Do:
get rid of 'throws Exception'

Field Summary
 
Fields inherited from class org.apache.commons.jelly.TagSupport
body, context, hasTrimmed, parent, shouldTrim
 
Constructor Summary
MavenTag()
           
 
Method Summary
 void doTag(XMLOutput output)
          Process the tag.
 java.io.File getDescriptor()
          Getter for the descriptor property
 java.lang.String getGoals()
          Getter for the goals property
 boolean isIgnoreFailures()
          Get the ignore failures flag.
 void setBasedir(java.io.File basedir)
          Deprecated. You only need to specify the project descriptor.
 void setDescriptor(java.io.File descriptor)
          Setter for the descriptor property
 void setGoals(java.lang.String goals)
          Setter for the goals property
 void setIgnoreFailures(boolean ignoreFailures)
          Set the ignore failures flag.
 
Methods inherited from class org.apache.maven.jelly.tags.BaseTagSupport
checkAttribute, getMavenContext
 
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

MavenTag

public MavenTag()
Method Detail

doTag

public void doTag(XMLOutput output)
           throws MissingAttributeException,
                  JellyTagException
Process the tag. Set up a new maven instance with the same maven home as the one under maven.obj in the context, add the provided goals and verify.

Parameters:
output - for providing xml output
Throws:
JellyTagException - if anything goes wrong.
MissingAttributeException

setDescriptor

public void setDescriptor(java.io.File descriptor)
Setter for the descriptor property

Parameters:
descriptor - the maven project descriptor to be read

getDescriptor

public java.io.File getDescriptor()
Getter for the descriptor property

Returns:
the maven project descriptor to be read

setBasedir

public void setBasedir(java.io.File basedir)
Deprecated. You only need to specify the project descriptor.

Setter for the basedir property

Parameters:
basedir - the base directory for execution of the project

setGoals

public void setGoals(java.lang.String goals)
Setter for the goals property

Parameters:
goals - a comma separated list of goal names to attain

getGoals

public java.lang.String getGoals()
Getter for the goals property

Returns:
a comma separated list of goal names to attain

setIgnoreFailures

public void setIgnoreFailures(boolean ignoreFailures)
Set the ignore failures flag.

Parameters:
ignoreFailures - The ignore failures flag.

isIgnoreFailures

public boolean isIgnoreFailures()
Get the ignore failures flag.

Returns:
boolean The ignores failure flag.


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