@Extension public class GerritManagement extends hudson.model.ManagementLink implements org.kohsuke.stapler.StaplerProxy, hudson.model.Describable<GerritManagement>, hudson.model.Saveable, jenkins.model.ModelObjectWithContextMenu
Modifier and Type | Class and Description |
---|---|
static class |
GerritManagement.DescriptorImpl
Descriptor is only used for UI form bindings.
|
Modifier and Type | Field and Description |
---|---|
static String |
URL_NAME
The relative url name for this management link.
|
Constructor and Description |
---|
GerritManagement() |
Modifier and Type | Method and Description |
---|---|
GerritServer |
doAddNewServer(org.kohsuke.stapler.StaplerRequest req,
org.kohsuke.stapler.StaplerResponse rsp)
Add a new server.
|
void |
doConfigSubmit(org.kohsuke.stapler.StaplerRequest req,
org.kohsuke.stapler.StaplerResponse rsp)
Saves the form to the configuration and disk.
|
jenkins.model.ModelObjectWithContextMenu.ContextMenu |
doContextMenu(org.kohsuke.stapler.StaplerRequest request,
org.kohsuke.stapler.StaplerResponse response) |
hudson.util.FormValidation |
doNameFreeCheck(String value)
Checks whether server name already exists.
|
static GerritManagement |
get()
Returns this singleton.
|
GerritAdministrativeMonitor |
getAdministrativeMonitor()
The AdministrativeMonitor related to Gerrit.
|
static IGerritHudsonTriggerConfig |
getConfig(String serverName)
Get the config of a server.
|
String |
getDescription() |
GerritManagement.DescriptorImpl |
getDescriptor() |
Diagnostics |
getDiagnostics()
A sub page displaying some diagnostic views.
|
String |
getDisplayName() |
String |
getIconFileName() |
static PluginConfig |
getPluginConfig()
Get the plugin config.
|
hudson.security.Permission |
getRequiredPermission()
Jenkins.ADMINISTER permission. |
GerritServer |
getServer(String encodedServerName)
Used when redirected to a server.
|
List<String> |
getServerNames()
Convenience method for jelly.
|
List<GerritServer> |
getServers()
Gets the list of GerritServer.
|
net.sf.json.JSONObject |
getServerStatuses()
Used when getting server status from JavaScript.
|
Object |
getTarget() |
String |
getUrlName() |
void |
save() |
public static final String URL_NAME
getUrlName()
.public String getIconFileName()
getIconFileName
in interface hudson.model.Action
getIconFileName
in class hudson.model.ManagementLink
public String getUrlName()
getUrlName
in interface hudson.model.Action
getUrlName
in class hudson.model.ManagementLink
public String getDisplayName()
getDisplayName
in interface hudson.model.Action
getDisplayName
in interface hudson.model.ModelObject
public String getDescription()
getDescription
in class hudson.model.ManagementLink
public GerritManagement.DescriptorImpl getDescriptor()
getDescriptor
in interface hudson.model.Describable<GerritManagement>
public jenkins.model.ModelObjectWithContextMenu.ContextMenu doContextMenu(org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response) throws Exception
doContextMenu
in interface jenkins.model.ModelObjectWithContextMenu
Exception
public Diagnostics getDiagnostics()
public List<GerritServer> getServers()
public GerritServer getServer(String encodedServerName)
encodedServerName
- the server name encoded by URLEncoder.encode(name,"UTF-8").@JavaScriptMethod public net.sf.json.JSONObject getServerStatuses()
public GerritServer doAddNewServer(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp) throws IOException
req
- the StaplerRequestrsp
- the StaplerResponseIOException
- when error sending redirect back to the list of serverspublic Object getTarget()
getTarget
in interface org.kohsuke.stapler.StaplerProxy
public void save() throws IOException
save
in interface hudson.model.Saveable
IOException
public static GerritManagement get()
@CheckForNull public static PluginConfig getPluginConfig()
public static IGerritHudsonTriggerConfig getConfig(String serverName)
serverName
- the name of the server for which we want to get the config.GerritServer.getConfig()
public GerritAdministrativeMonitor getAdministrativeMonitor()
public List<String> getServerNames()
public hudson.util.FormValidation doNameFreeCheck(@QueryParameter(value="value") String value)
value
- the value of the name field.public void doConfigSubmit(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp) throws javax.servlet.ServletException, IOException, InterruptedException
req
- StaplerRequestrsp
- StaplerResponsejavax.servlet.ServletException
- if something unfortunate happens.IOException
- if something unfortunate happens.InterruptedException
- if something unfortunate happens.public hudson.security.Permission getRequiredPermission()
Jenkins.ADMINISTER
permission.
Also used by JellygetRequiredPermission
in class hudson.model.ManagementLink
Copyright © 2016–2020. All rights reserved.