public class Utils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
createRandomParameterName(String prefix,
String suffix)
Creates a random parameter name.
|
static String |
escapeSelected(Object obj)
Escapes the parameter value, removing the :selected suffix.
|
static hudson.model.Project |
findProjectByParameterUUID(String parameterUUID)
Find the current project give its parameter UUID.
|
static Set<org.jenkinsci.plugins.scriptler.config.Script> |
getAllScriptlerScripts()
Returns all scriptler scripts available.
|
static hudson.model.Project<?,?> |
getProjectByName(String projectName)
Get project in Jenkins given its name.
|
static List<hudson.model.ParameterDefinition> |
getProjectParameterDefinitions(hudson.model.Project project)
Get the parameter definitions for the given project.
|
static Map<String,String> |
getSystemEnv()
Helped method to return the system environment variables.
|
static boolean |
isSelected(Object obj)
Checks whether a parameter value contains the :selected suffix, returning
true if it does, false otherwise. |
public static Set<org.jenkinsci.plugins.scriptler.config.Script> getAllScriptlerScripts()
public static boolean isSelected(Object obj)
true if it does, false otherwise.obj - parameter valuetrue if the parameter name contains the :selected suffix false otherwise.public static String escapeSelected(Object obj)
obj - parameter valuepublic static String createRandomParameterName(String prefix, String suffix)
prefix - parameter prefixsuffix - parameter suffixpublic static Map<String,String> getSystemEnv()
public static hudson.model.Project<?,?> getProjectByName(String projectName)
projectName - project name in Jenkinsnull if none with this namepublic static hudson.model.Project findProjectByParameterUUID(String parameterUUID)
parameterUUID - parameter UUIDnull if the current project cannot be foundpublic static List<hudson.model.ParameterDefinition> getProjectParameterDefinitions(hudson.model.Project project)
project - the project for which the parameter definitions should be foundCopyright © 2004-2015. All Rights Reserved.