Package org.ow2.clif.jenkins
Class ClifPlugin
java.lang.Object
hudson.model.Descriptor<GlobalConfiguration>
jenkins.model.GlobalConfiguration
org.ow2.clif.jenkins.ClifPlugin
- All Implemented Interfaces:
ExtensionPoint,Describable<GlobalConfiguration>,Saveable,Loadable,OnMaster
Global configuration parameters for the Clif plugin.
As of today, there is a single parameter: clifRootDir.
It specifies the folder where to unzip imported CLIF project archives.
Such imported archives will possibly result is having multiple jobs
(one per imported test plan) sharing a single workspace containing all
files extracted from one CLIF project archive.
Each imported archive gets its own sub-folder created in the
configured root folder. This sub-folder is named according to the
CLIF project folder's name in the archive.
- Author:
- Julien Coste, Bruno Dillenseger
-
Nested Class Summary
Nested classes/interfaces inherited from class hudson.model.Descriptor
Descriptor.FormException, Descriptor.PropertyType, Descriptor.SelfNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Field Summary
FieldsFields inherited from class hudson.model.Descriptor
clazz -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondir()Returns the File object representing the configured clif root directory in its absolute path form.doCheckClifRootDir(String value) Validates a CLIF root folder.static ClifPluginget()Get the ClifPlugin singleton managing CLIF's global parametersGets current value of CLIF root directory where CLIF archives are unzipped.voidload()Loads the currently configured valuesvoidsetClifRootDir(String clifRootDir) Configures a new value for CLIF root directory where CLIF archives are unzipped.Methods inherited from class jenkins.model.GlobalConfiguration
all, configure, configure, getDescriptor, getGlobalConfigPageMethods inherited from class hudson.model.Descriptor
addHelpFileRedirect, bindJSON, bindJSON, calcAutoCompleteSettings, calcFillSettings, configure, doHelp, doHelp, find, find, findByDescribableClassName, findById, getCategory, getCheckMethod, getCheckUrl, getConfigFile, getConfigPage, getCurrentDescriptorByNameUrl, getDescriptorFullUrl, getDescriptorUrl, getDisplayName, getGlobalPropertyType, getHelpFile, getHelpFile, getHelpFile, getId, getJsonSafeClassName, getKlass, getPlugin, getPossibleViewNames, getPropertyType, getPropertyType, getPropertyTypeOrDie, getRequiredGlobalConfigPagePermission, getStaticHelpUrl, getStaticHelpUrl, getT, getViewPage, isInstance, isSubTypeOf, newInstance, newInstance, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, save, self, toArray, toList, toMap
-
Field Details
-
DEFAULT_ROOT_DIR
- See Also:
-
-
Constructor Details
-
ClifPlugin
public ClifPlugin()Just callsload()
-
-
Method Details
-
get
Get the ClifPlugin singleton managing CLIF's global parameters- Returns:
- the ClifPlugin singleton
-
load
public void load()Loads the currently configured values- Specified by:
loadin interfaceLoadable- Overrides:
loadin classDescriptor<GlobalConfiguration>
-
getClifRootDir
Gets current value of CLIF root directory where CLIF archives are unzipped.- Returns:
- The configured Clif root directory.
-
setClifRootDir
Configures a new value for CLIF root directory where CLIF archives are unzipped.- Parameters:
clifRootDir- the new root directory for imported CLIF projects. If blank, the new value is set to the default value "clif"
-
dir
Returns the File object representing the configured clif root directory in its absolute path form. When the configured root folder is a relative path, it is resolved from the Jenkins' installation root directory.- Returns:
- A file object representing the configured Clif root parameter
-
doCheckClifRootDir
Validates a CLIF root folder. The folder is valid either if it exists, is actually a folder and is writable, or if the closest existing parent file in its absolute path is a writable folder. In other words, validation relies on the availability of the CLIF root folder or the ability to create it.- Parameters:
value- the new value for CLIF root folder- Returns:
- validation result (ok or error) with an explicit, localized message.
-