org.jvnet.hudson.maven.plugins.hudson
Class AdjustViolationsMojo

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.jvnet.hudson.maven.plugins.hudson.AbstractHudsonMojo
          extended by org.jvnet.hudson.maven.plugins.hudson.AdjustViolationsMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

public class AdjustViolationsMojo
extends AbstractHudsonMojo

Mojo that changes the settings of the Violations Hudson plugin.

Author:
edelsonj

Nested Class Summary
 
Nested classes/interfaces inherited from class org.jvnet.hudson.maven.plugins.hudson.AbstractHudsonMojo
AbstractHudsonMojo.JobClosure, AbstractHudsonMojo.PluginType
 
Field Summary
 
Fields inherited from class org.jvnet.hudson.maven.plugins.hudson.AbstractHudsonMojo
httpClient, hudsonURL, project, settings
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
AdjustViolationsMojo()
           
 
Method Summary
protected  void changeJob(java.lang.String name)
           
protected  boolean changeViolations(org.jdom.Document jobDoc)
          Change the configuration of the Violations plugin with the appropriate min, max, and unstable values.
 void execute()
           
 
Methods inherited from class org.jvnet.hudson.maven.plugins.hudson.AbstractHudsonMojo
configurePlugin, createHudsonURL, createJobBuildURL, createJobConfigURL, createJobListURL, createOrChange, createOrChange, doPost, doPost, findServer, forEachJob, getDocumentFromHudson, getJobList, loadJobConfig, rebuildJob, saveJobConfig, setupClient
 
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AdjustViolationsMojo

public AdjustViolationsMojo()
Method Detail

execute

public void execute()
             throws org.apache.maven.plugin.MojoExecutionException,
                    org.apache.maven.plugin.MojoFailureException
Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException

changeJob

protected void changeJob(java.lang.String name)
                  throws org.apache.maven.plugin.MojoExecutionException
Throws:
org.apache.maven.plugin.MojoExecutionException

changeViolations

protected boolean changeViolations(org.jdom.Document jobDoc)
                            throws org.jdom.JDOMException
Change the configuration of the Violations plugin with the appropriate min, max, and unstable values.

Parameters:
jobDoc - the job Document
Returns:
true if the violations Element was changed
Throws:
org.jdom.JDOMException - if the


Copyright © 1981-2010 MTV Networks. All Rights Reserved.