package org.jenkinsci.plugins.p4.populate;
import org.kohsuke.stapler.export.Exported;
import org.kohsuke.stapler.export.ExportedBean;
import hudson.model.BuildBadgeAction;
/**
*
* @author dawn
*/
@ExportedBean(defaultVisibility = 999)
public class PopulateBuildBadgeAction implements BuildBadgeAction{
// iconPath can be set to e.g. "/plugin/p4/images/<iconfile>" to pick up images from the p4 plugin.
// Can also set it to just the file name, and specify path details in the relevant jelly files.
private final String iconPath;
private final String text;
public PopulateBuildBadgeAction(String iconPath, String text){
this.iconPath = iconPath;
this.text = text;
}
public String getUrlName(){
return "";
}
@Exported
public String getDisplayName() {
return text;
}
public String getIconFileName() {
return iconPath;
}
}