mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-10-31 13:35:19 +00:00
[FIXED HUDSON-2763] Add health report in build history widget on project page.
git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@13802 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
1 parent
1514352c02
commit
356fdbec0d
5 files changed
+81
-48
No files matched your search
@@ -35,6 +35,9 @@ import hudson.util.Area;
|
||||
import hudson.util.Iterators;
|
||||
import org.acegisecurity.providers.anonymous.AnonymousAuthenticationToken;
|
||||
import org.apache.commons.jelly.JellyContext;
|
||||
import org.apache.commons.jelly.JellyTagException;
|
||||
import org.apache.commons.jelly.Script;
|
||||
import org.apache.commons.jelly.XMLOutput;
|
||||
import org.apache.commons.jexl.parser.ASTSizeFunction;
|
||||
import org.apache.commons.jexl.util.Introspector;
|
||||
import org.kohsuke.stapler.Ancestor;
|
||||
@@ -871,6 +874,17 @@ public class Functions {
|
||||
return context;
|
||||
}
|
||||
|
||||
/**
|
||||
* Evaluate a Jelly script and return output as a String.
|
||||
*
|
||||
* @since 1.267
|
||||
*/
|
||||
public static String runScript(Script script) throws JellyTagException {
|
||||
StringWriter out = new StringWriter();
|
||||
script.run(getCurrentJellyContext(), XMLOutput.createXMLOutput(out));
|
||||
return out.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a sub-list if the given list is bigger than the specified 'maxSize'
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user