Package hudson.plugins.gearman
Class GearmanPluginConfig
java.lang.Object
hudson.model.Descriptor<GlobalConfiguration>
jenkins.model.GlobalConfiguration
hudson.plugins.gearman.GearmanPluginConfig
- All Implemented Interfaces:
ExtensionPoint
,Describable<GlobalConfiguration>
,Saveable
,Loadable
,OnMaster
This class is used to set the global configuration for the gearman-plugin It
is also used to enable/disable the gearman plugin.
- Author:
- Khai Do
-
Nested Class Summary
Nested classes/interfaces inherited from class hudson.model.Descriptor
Descriptor.FormException, Descriptor.PropertyType, Descriptor.Self
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Field Summary
Fields inherited from class hudson.model.Descriptor
clazz
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
configure
(org.kohsuke.stapler.StaplerRequest2 req, net.sf.json.JSONObject json) doTestConnection
(String host, int port) static GearmanPluginConfig
get()
getHost()
This method returns the value from the server host text boxint
getPort()
This method returns the value from the server port text boxboolean
This method returns true if the global configuration says we should enable the plugin.void
setEnablePlugin
(boolean enablePlugin) void
void
setPort
(int port) Methods inherited from class jenkins.model.GlobalConfiguration
all, configure, getDescriptor, getGlobalConfigPage
Methods 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, load, newInstance, newInstance, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, save, self, toArray, toList, toMap
-
Constructor Details
-
GearmanPluginConfig
public GearmanPluginConfig()Constructor.
-
-
Method Details
-
get
-
doTestConnection
public FormValidation doTestConnection(@QueryParameter("host") String host, @QueryParameter("port") int port) throws IOException, jakarta.servlet.ServletException - Throws:
IOException
jakarta.servlet.ServletException
-
configure
public boolean configure(org.kohsuke.stapler.StaplerRequest2 req, net.sf.json.JSONObject json) throws Descriptor.FormException - Overrides:
configure
in classGlobalConfiguration
- Throws:
Descriptor.FormException
-
setHost
-
setPort
@DataBoundSetter public void setPort(int port) -
setEnablePlugin
@DataBoundSetter public void setEnablePlugin(boolean enablePlugin) -
isEnablePlugin
public boolean isEnablePlugin()This method returns true if the global configuration says we should enable the plugin. -
getHost
This method returns the value from the server host text box -
getPort
public int getPort()This method returns the value from the server port text box
-