hudson.plugins.jswidgets
Class JsBuildAction

java.lang.Object
  extended by hudson.plugins.jswidgets.JsBaseAction
      extended by hudson.plugins.jswidgets.JsBuildAction
All Implemented Interfaces:
Action, ModelObject

public class JsBuildAction
extends JsBaseAction

This class implements the JS widgets pages for a build.

Author:
mfriedenhagen

Field Summary
private  AbstractBuild<?,?> build
          the build this action acts on.
private static HashMap<EditType,String> EDIT_TYPE_SYMBOLS
          describe type of edits.
private static Logger LOG
          Our logger.
 
Constructor Summary
JsBuildAction(AbstractBuild<?,?> build)
           
 
Method Summary
 AbstractBuild<?,?> getBuild()
          Returns the build.
 String getBuiltOn()
          Returns the Name of the Node where the AbstractBuild happened.
 Collection<String> getChangeSetEntries(ChangeLogSet.Entry entry)
          Returns a representation for affected files in entry prefixing them with the EditType of the change.
 AbstractProject<?,?> getProject()
          Returns the project.
 String getUrlName()
          
 
Methods inherited from class hudson.plugins.jswidgets.JsBaseAction
getBaseUrl, getDisplayName, getIconFileName, getImagesUrl, wantHtml
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

private static final Logger LOG
Our logger.


build

private final AbstractBuild<?,?> build
the build this action acts on.


EDIT_TYPE_SYMBOLS

private static final HashMap<EditType,String> EDIT_TYPE_SYMBOLS
describe type of edits.

Constructor Detail

JsBuildAction

public JsBuildAction(AbstractBuild<?,?> build)
Parameters:
build - this action acts on.
Method Detail

getUrlName

public String getUrlName()

Specified by:
getUrlName in interface Action
Overrides:
getUrlName in class JsBaseAction

getBuild

public AbstractBuild<?,?> getBuild()
Returns the build.

Returns:
the build.

getProject

public AbstractProject<?,?> getProject()
Returns the project.

Returns:
the project.

getBuiltOn

public String getBuiltOn()
Returns the Name of the Node where the AbstractBuild happened. If the Node is deleted meanwhile it returns UNKNOWN.

Returns:
name of the node.

getChangeSetEntries

public Collection<String> getChangeSetEntries(ChangeLogSet.Entry entry)
Returns a representation for affected files in entry prefixing them with the EditType of the change. Some SCMs do not support ChangeLogSet.Entry.getAffectedFiles(), so do fall back to ChangeLogSet.Entry.getAffectedPaths() in this case.

Parameters:
entry - changeset.
Returns:
collection of EditType prefixed paths.


Copyright © 2010. All Rights Reserved.