|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.prompts.definitions.IntegerRangeDefinition
public class IntegerRangeDefinition
IntegerRangeDefinition is a prompt type which allows the specification of an integer range consisting of a minimum and maximum value.
Field Summary | |
---|---|
static java.lang.String |
RB_KEY
|
Constructor Summary | |
---|---|
IntegerRangeDefinition()
Constructor |
|
IntegerRangeDefinition(java.lang.String promptName)
Constructor |
Method Summary | |
---|---|
void |
configureAttributes(java.util.Map options,
java.util.Map context)
|
java.util.List |
getAttributeDescriptors(java.util.Locale locale)
|
protected java.util.Map<java.lang.String,java.lang.String> |
getConstraints(java.util.Locale locale)
|
protected java.lang.String |
getDefaultMaxLabel(java.util.Locale locale)
Returns the default label for the maximum field when one is not set by the user. |
protected java.lang.String |
getDefaultMinLabel(java.util.Locale locale)
Returns the default label for the minimum field when one is not set by the user. |
int |
getMaximum()
Returns the maximum valid value for the prompt value. |
int |
getMinimum()
Returns the minimum valid value for the prompt value. |
com.sas.datatypes.DataTypeInterface |
getPromptDataType()
Returns the data type used to manipulate the value for the prompt definition. |
java.util.Collection |
getPromptValueValidationErrors(java.lang.Object value,
java.util.Locale locale)
Returns a Collection containing the set of ValidationEntry objects or an empty
collection if no errors were found. |
boolean |
isPromptValueValid(java.lang.Object value,
java.util.Locale locale)
Returns whether the value passed in is a valid value for this prompt definition. |
void |
setMaximum(int maximum)
Sets the maximum valid value for the prompt value. |
void |
setMinimum(int minimum)
Sets the minimum valid value for the prompt value. |
java.util.Collection |
validateDefinition(java.util.Locale locale)
This method is used to validate that the various attributes of the definition all contain valid values. |
Methods inherited from class com.sas.prompts.definitions.BaseDefinitionRange |
---|
getMaxLabel, getMaxLabels, getMinLabel, getMinLabels, isRequired, populateErrorsForMinMax, populateMapWithErrorsForValue, setMaxLabel, setMaxLabels, setMinLabel, setMinLabels, setRequired |
Methods inherited from interface com.sas.prompts.definitions.PromptDefinitionInterface |
---|
clearDefaultValue, getDefaultValue, getPromptDescription, getPromptDescriptions, getPromptLabel, getPromptLabels, getPromptName, getUserInfo, isDefaultValueSet, isFixed, isHidden, isPromptValueValid |
Methods inherited from interface com.sas.prompts.definitions.MutableRequiredDefinitionInterface |
---|
setRequired |
Field Detail |
---|
public static final java.lang.String RB_KEY
Constructor Detail |
---|
public IntegerRangeDefinition()
public IntegerRangeDefinition(java.lang.String promptName)
Method Detail |
---|
protected java.lang.String getDefaultMaxLabel(java.util.Locale locale)
getDefaultMaxLabel
in class BaseDefinitionRange
locale
- The locale the retrieve the label for
protected java.lang.String getDefaultMinLabel(java.util.Locale locale)
getDefaultMinLabel
in class BaseDefinitionRange
locale
- The locale the retrieve the label for
public int getMinimum()
getMinimum
in interface com.sas.prompts.definitions.IntegerRangeDefinitionInterface
public void setMinimum(int minimum)
setMinimum
in interface com.sas.prompts.definitions.MutableIntegerRangeDefinitionInterface
minimum
- the minimum valid value for the prompt value.public int getMaximum()
getMaximum
in interface com.sas.prompts.definitions.IntegerRangeDefinitionInterface
public void setMaximum(int maximum)
setMaximum
in interface com.sas.prompts.definitions.MutableIntegerRangeDefinitionInterface
maximum
- the maximum valid value for the prompt value.public boolean isPromptValueValid(java.lang.Object value, java.util.Locale locale)
isPromptValueValid
in interface com.sas.prompts.definitions.PromptDefinitionV2Interface
isPromptValueValid
in class PromptDefinition
value
- The value to check for validity
PromptDefinitionV2Interface.isPromptValueValid(java.lang.Object, java.util.Locale)
public java.util.Collection getPromptValueValidationErrors(java.lang.Object value, java.util.Locale locale)
ValidationEntry
objects or an empty
collection if no errors were found.
getPromptValueValidationErrors
in interface PromptDefinitionInterface
getPromptValueValidationErrors
in class PromptDefinition
value
- The value to check for errorslocale
- The locale to return the error messages in
ValidationEntry
objects or an empty
collection if no errors were found.PromptDefinitionInterface.getPromptValueValidationErrors(Object, Locale)
public java.util.Collection validateDefinition(java.util.Locale locale)
ValidationEntry
objects
for each error. This method should be called before the definition is to be used.
Subclasses should override this method to return the appropriate validation errors.
validateDefinition
in interface PromptDefinitionInterface
validateDefinition
in class PromptDefinition
locale
- The locale to return the error messages in
ValidationEntry
objects or an empty
collection if no errors were found.PromptDefinitionInterface.validateDefinition(Locale)
public com.sas.datatypes.DataTypeInterface getPromptDataType()
getPromptDataType
in interface PromptDefinitionInterface
getPromptDataType
in class PromptDefinition
PromptDefinitionInterface.getPromptDataType()
public java.util.List getAttributeDescriptors(java.util.Locale locale)
getAttributeDescriptors
in interface com.sas.util.AttributeDescription
getAttributeDescriptors
in class BaseDefinitionRange
public void configureAttributes(java.util.Map options, java.util.Map context)
configureAttributes
in interface com.sas.util.AttributeConfigurationInterface
configureAttributes
in class BaseDefinitionRange
protected java.util.Map<java.lang.String,java.lang.String> getConstraints(java.util.Locale locale)
getConstraints
in class PromptDefinition
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |