hudson.scm
Class IntegritySCM.DescriptorImpl

java.lang.Object
  extended by hudson.model.Descriptor<hudson.scm.SCM>
      extended by hudson.scm.SCMDescriptor<IntegritySCM>
          extended by hudson.scm.IntegritySCM.DescriptorImpl
All Implemented Interfaces:
hudson.model.Saveable
Enclosing class:
IntegritySCM

public static class IntegritySCM.DescriptorImpl
extends hudson.scm.SCMDescriptor<IntegritySCM>

The relationship of Descriptor and SCM (the describable) is akin to class and object. This means the descriptor is used to create instances of the describable. Usually the Descriptor is an internal class in the SCM class named DescriptorImpl. The Descriptor should also contain the global configuration options as fields, just like the SCM class contains the configurations options for a job.


Nested Class Summary
 
Nested classes/interfaces inherited from class hudson.model.Descriptor
hudson.model.Descriptor.FormException, hudson.model.Descriptor.PropertyType
 
Field Summary
static IntegritySCM.DescriptorImpl INTEGRITY_DESCRIPTOR
           
 
Fields inherited from class hudson.scm.SCMDescriptor
generation, repositoryBrowser
 
Fields inherited from class hudson.model.Descriptor
clazz
 
Fields inherited from interface hudson.model.Saveable
NOOP
 
Constructor Summary
protected IntegritySCM.DescriptorImpl()
           
 
Method Summary
 boolean configure(org.kohsuke.stapler.StaplerRequest req, net.sf.json.JSONObject formData)
          This method is invoked when the global configuration page is submitted.
 hudson.util.FormValidation doValidPortCheck(String value)
          Validates that the port number is numeric and within a valid range
 String getDefaultHostName()
          Returns the default host name for the Integrity Server
 String getDefaultIPHostName()
          Returns the default Integration Point host name
 int getDefaultIPPort()
          Returns the default Integration Point port
 String getDefaultPassword()
          Returns the default user's password connecting to the Integrity Server
 int getDefaultPort()
          Returns the default port for the Integrity Server
 boolean getDefaultSecure()
          Returns the default secure setting for the Integrity Server
 String getDefaultUserName()
          Returns the default User connecting to the Integrity Server
 String getDisplayName()
          Returns the name of the SCM, this is the name that will show up next to CVS, Subversion, etc.
 hudson.scm.SCM newInstance(org.kohsuke.stapler.StaplerRequest req, net.sf.json.JSONObject formData)
           
 void setDefaultHostName(String defaultHostName)
          Sets the default host name for the Integrity Server
 void setDefaultIPHostName(String defaultIPHostName)
          Sets the default host name for the Integration Point
 void setDefaultIPPort(int defaultIPPort)
          Sets the default port for the Integration Point
 void setDefaultPassword(String defaultPassword)
          Sets the encrypted Password of the default user connecting to the Integrity Server
 void setDefaultPort(int defaultPort)
          Sets the default port for the Integrity Server
 void setDefaultSecure(boolean defaultSecure)
          Toggles whether or not secure sockets are enabled
 void setDefaultUserName(String defaultUserName)
          Sets the default User connecting to the Integrity Server
 
Methods inherited from class hudson.scm.SCMDescriptor
getBrowserDescriptors, getGeneration, isApplicable, isBrowserReusable, load
 
Methods inherited from class hudson.model.Descriptor
calcAutoCompleteSettings, calcFillSettings, configure, doHelp, find, find, getCheckUrl, getConfigFile, getConfigPage, getDescriptorUrl, getGlobalConfigPage, getGlobalPropertyType, getHelpFile, getHelpFile, getId, getJsonSafeClassName, getPropertyType, getPropertyType, getViewPage, isInstance, isSubTypeOf, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, save, toArray, toList, toMap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INTEGRITY_DESCRIPTOR

@Extension
public static final IntegritySCM.DescriptorImpl INTEGRITY_DESCRIPTOR
Constructor Detail

IntegritySCM.DescriptorImpl

protected IntegritySCM.DescriptorImpl()
Method Detail

newInstance

public hudson.scm.SCM newInstance(org.kohsuke.stapler.StaplerRequest req,
                                  net.sf.json.JSONObject formData)
                           throws hudson.model.Descriptor.FormException
Overrides:
newInstance in class hudson.model.Descriptor<hudson.scm.SCM>
Throws:
hudson.model.Descriptor.FormException

getDisplayName

public String getDisplayName()
Returns the name of the SCM, this is the name that will show up next to CVS, Subversion, etc. when configuring a job.

Specified by:
getDisplayName in class hudson.model.Descriptor<hudson.scm.SCM>

configure

public boolean configure(org.kohsuke.stapler.StaplerRequest req,
                         net.sf.json.JSONObject formData)
                  throws hudson.model.Descriptor.FormException
This method is invoked when the global configuration page is submitted. In the method the data in the web form should be copied to the Descriptor's fields. To persist the fields to the global configuration XML file, the save() method must be called. Data is defined in the global.jelly page.

Overrides:
configure in class hudson.model.Descriptor<hudson.scm.SCM>
Throws:
hudson.model.Descriptor.FormException

getDefaultHostName

public String getDefaultHostName()
Returns the default host name for the Integrity Server

Returns:
defaultHostName

getDefaultIPHostName

public String getDefaultIPHostName()
Returns the default Integration Point host name

Returns:
defaultIPHostName

getDefaultPort

public int getDefaultPort()
Returns the default port for the Integrity Server

Returns:
defaultPort

getDefaultIPPort

public int getDefaultIPPort()
Returns the default Integration Point port

Returns:
defaultIPPort

getDefaultSecure

public boolean getDefaultSecure()
Returns the default secure setting for the Integrity Server

Returns:
defaultSecure

getDefaultUserName

public String getDefaultUserName()
Returns the default User connecting to the Integrity Server

Returns:
defaultUserName

getDefaultPassword

public String getDefaultPassword()
Returns the default user's password connecting to the Integrity Server

Returns:
defaultPassword

setDefaultHostName

public void setDefaultHostName(String defaultHostName)
Sets the default host name for the Integrity Server

Parameters:
defaultHostName -

setDefaultIPHostName

public void setDefaultIPHostName(String defaultIPHostName)
Sets the default host name for the Integration Point

Parameters:
defaultIPHostName -

setDefaultPort

public void setDefaultPort(int defaultPort)
Sets the default port for the Integrity Server

Parameters:
defaultPort -

setDefaultIPPort

public void setDefaultIPPort(int defaultIPPort)
Sets the default port for the Integration Point

Parameters:
defaultIPPort -

setDefaultSecure

public void setDefaultSecure(boolean defaultSecure)
Toggles whether or not secure sockets are enabled

Parameters:
defaultSecure -

setDefaultUserName

public void setDefaultUserName(String defaultUserName)
Sets the default User connecting to the Integrity Server

Parameters:
defaultUserName -

setDefaultPassword

public void setDefaultPassword(String defaultPassword)
Sets the encrypted Password of the default user connecting to the Integrity Server

Parameters:
defaultPassword -

doValidPortCheck

public hudson.util.FormValidation doValidPortCheck(@QueryParameter
                                                   String value)
Validates that the port number is numeric and within a valid range

Parameters:
value - Integer value for Port or IP Port
Returns:


Copyright © 2004-2012 Hudson. All Rights Reserved.