public class ExtensibleChoiceParameterDefinition
extends hudson.model.SimpleParameterDefinition
| Modifier and Type | Class and Description |
|---|---|
static class |
ExtensibleChoiceParameterDefinition.DescriptorImpl
The internal class to work with views.
|
static class |
ExtensibleChoiceParameterDefinition.DescriptorVisibilityFilterImpl |
| Constructor and Description |
|---|
ExtensibleChoiceParameterDefinition(String name,
ChoiceListProvider choiceListProvider,
boolean editable,
String description)
Constructor instantiating with parameters in the configuration page.
|
| Modifier and Type | Method and Description |
|---|---|
hudson.model.ParameterValue |
createValue(org.kohsuke.stapler.StaplerRequest request,
net.sf.json.JSONObject jo)
Decide a value of this parameter from the user input.
|
hudson.model.ParameterValue |
createValue(String value)
Decide a value of this parameter from the user input.
|
protected hudson.model.ParameterValue |
createValueCommon(hudson.model.StringParameterValue value)
Test passed ParameterValue and return.
|
List<String> |
getChoiceList()
Return choices available for this parameter.
|
ChoiceListProvider |
getChoiceListProvider()
The choice provider the user specified.
|
hudson.model.ParameterValue |
getDefaultParameterValue()
Returns the default value of this parameter.
|
ChoiceListProvider |
getEnabledChoiceListProvider() |
static Pattern |
getNamePattern()
Deprecated.
|
boolean |
isEditable()
Is this parameter value can be set to a value not in the choices?
|
@DataBoundConstructor public ExtensibleChoiceParameterDefinition(String name, ChoiceListProvider choiceListProvider, boolean editable, String description)
name - the name of this parameter (used as a variable name).choiceListProvider - the choice providereditable - whether this parameter can be a value not in choices.description - the description of this parameter. Used only for the convenience of users.@Deprecated public static Pattern getNamePattern()
public boolean isEditable()
public ChoiceListProvider getChoiceListProvider()
public ChoiceListProvider getEnabledChoiceListProvider()
ExtensibleChoiceParameterDefinition.DescriptorImpl.isProviderEnabled(Descriptor)public List<String> getChoiceList()
protected hudson.model.ParameterValue createValueCommon(hudson.model.StringParameterValue value)
value - a value to test.public hudson.model.ParameterValue createValue(org.kohsuke.stapler.StaplerRequest request,
net.sf.json.JSONObject jo)
createValue in class hudson.model.ParameterDefinitionrequest - jo - the user inputParameterDefinition.createValue(org.kohsuke.stapler.StaplerRequest, net.sf.json.JSONObject)public hudson.model.ParameterValue createValue(String value) throws IllegalArgumentException
createValue in class hudson.model.SimpleParameterDefinitionvalue - the user inputIllegalArgumentException - The value is not in choices even the field is not editable.SimpleParameterDefinition.createValue(java.lang.String)public hudson.model.ParameterValue getDefaultParameterValue()
getDefaultParameterValue in class hudson.model.ParameterDefinitionParameterDefinition.getDefaultParameterValue()Copyright © 2004-2015. All Rights Reserved.