Package hudson.model
Class PasswordParameterDefinition
- java.lang.Object
-
- hudson.model.ParameterDefinition
-
- hudson.model.SimpleParameterDefinition
-
- hudson.model.PasswordParameterDefinition
-
- All Implemented Interfaces:
ExtensionPoint
,Describable<ParameterDefinition>
,Serializable
public class PasswordParameterDefinition extends SimpleParameterDefinition
Parameter whose value is aSecret
and is hidden from the UI.- Since:
- 1.319
- Author:
- Kohsuke Kawaguchi
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PasswordParameterDefinition.ParameterDescriptorImpl
-
Nested classes/interfaces inherited from class hudson.model.ParameterDefinition
ParameterDefinition.ParameterDescriptor
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Field Summary
Fields Modifier and Type Field Description static String
DEFAULT_VALUE
-
Fields inherited from class hudson.model.ParameterDefinition
LIST
-
-
Constructor Summary
Constructors Constructor Description PasswordParameterDefinition(String name, Secret defaultValueAsSecret, String description)
PasswordParameterDefinition(String name, String defaultValue, String description)
Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ParameterDefinition
copyWithDefaultValue(ParameterValue defaultValue)
Create a new instance of this parameter definition and use the passed parameter value as the default value.ParameterValue
createValue(String value)
Creates aParameterValue
from the string representation.PasswordParameterValue
createValue(org.kohsuke.stapler.StaplerRequest req, net.sf.json.JSONObject jo)
Create a parameter value from a form submission.boolean
equals(Object obj)
ParameterValue
getDefaultParameterValue()
Returns default parameter value for this definition.String
getDefaultValue()
Secret
getDefaultValueAsSecret()
int
hashCode()
void
setDefaultValue(String defaultValue)
-
Methods inherited from class hudson.model.SimpleParameterDefinition
createValue, createValue
-
Methods inherited from class hudson.model.ParameterDefinition
all, getDescription, getDescriptor, getFormattedDescription, getName, getType, isValid, setDescription
-
-
-
-
Field Detail
-
DEFAULT_VALUE
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public static final String DEFAULT_VALUE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
PasswordParameterDefinition
@Deprecated public PasswordParameterDefinition(@NonNull String name, @CheckForNull String defaultValue, @CheckForNull String description)
Deprecated.
-
-
Method Detail
-
copyWithDefaultValue
public ParameterDefinition copyWithDefaultValue(ParameterValue defaultValue)
Description copied from class:ParameterDefinition
Create a new instance of this parameter definition and use the passed parameter value as the default value.- Overrides:
copyWithDefaultValue
in classParameterDefinition
-
createValue
public ParameterValue createValue(String value)
Description copied from class:SimpleParameterDefinition
Creates aParameterValue
from the string representation.- Specified by:
createValue
in classSimpleParameterDefinition
-
createValue
public PasswordParameterValue createValue(org.kohsuke.stapler.StaplerRequest req, net.sf.json.JSONObject jo)
Description copied from class:ParameterDefinition
Create a parameter value from a form submission.This method is invoked when the user fills in the parameter values in the HTML form and submits it to the server.
- Specified by:
createValue
in classParameterDefinition
-
getDefaultParameterValue
public ParameterValue getDefaultParameterValue()
Description copied from class:ParameterDefinition
Returns default parameter value for this definition.- Overrides:
getDefaultParameterValue
in classParameterDefinition
- Returns:
- default parameter value or null if no defaults are available
-
getDefaultValue
@NonNull public String getDefaultValue()
-
getDefaultValueAsSecret
@Restricted(org.kohsuke.accmod.restrictions.DoNotUse.class) public Secret getDefaultValueAsSecret()
-
setDefaultValue
public void setDefaultValue(String defaultValue)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classParameterDefinition
-
equals
public boolean equals(Object obj)
- Overrides:
equals
in classParameterDefinition
-
-