Package com.uc4.api.prompt
Class NumberElement
- java.lang.Object
- 
- com.uc4.api.objects.PromptElement
- 
- com.uc4.api.prompt.NumberElement
 
 
- 
- All Implemented Interfaces:
- PromptInterfaces.Caption,- PromptInterfaces.Constraints<java.lang.Integer>,- PromptInterfaces.DataReference,- PromptInterfaces.Focus,- PromptInterfaces.Locked,- PromptInterfaces.QuoteCharacter
 
 public class NumberElement extends PromptElement implements PromptInterfaces.Caption, PromptInterfaces.DataReference, PromptInterfaces.Focus, PromptInterfaces.QuoteCharacter, PromptInterfaces.Locked, PromptInterfaces.Constraints<java.lang.Integer> Number field.
- 
- 
Field Summary- 
Fields inherited from class com.uc4.api.objects.PromptElementaliasMap, list, properties
 
- 
 - 
Constructor SummaryConstructors Constructor Description NumberElement(java.lang.String variableName, UC4ObjectName reference)Creates a new number field.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.StringgetCaption()UC4ObjectNamegetDataReference()intgetMaximumValue()Deprecated.use getMaxValue() insteadjava.lang.IntegergetMaxValue()Returns the maximum value.intgetMinimumValue()Deprecated.Use getMinValue() insteadjava.lang.IntegergetMinValue()Returns the minimum value.chargetQuoteCharacter()Returns the character for a quote.protected java.lang.StringgetTagName()java.lang.StringgetTooltip()Returns the tooltip of this Prompt Element.booleanhasFocus()Returnstrueif the focus is set.booleanisLocked()Returnstrueif this Prompt Element is locked.protected java.lang.StringlistParam()voidsetCaption(java.lang.String caption)Sets the caption of this prompt element.voidsetDataReference(UC4ObjectName vara)Sets a UC4 VARA Object which contains a list of valid entries for this prompt element.voidsetFocus(boolean value)Sets the cursor focus: The cursor is placed at this control if the value istrue.voidsetLocked(boolean locked)Lock or unlocks this element.voidsetMaximumValue(int value)Deprecated.Use setMaxValue() insteadvoidsetMaxValue(java.lang.Integer value)Sets the maximum value.voidsetMinimumValue(int min)Deprecated.Use setMinValue() insteadvoidsetMinValue(java.lang.Integer min)Sets the minimum value.voidsetQuoteCharacter(char c)Sets the character for a quote, for example ' or ".voidsetTooltip(java.lang.String tooltip)Sets the tooltip of this Prompt Element.- 
Methods inherited from class com.uc4.api.objects.PromptElementgetCustomField, getMessageInsert, getMessageNumber, getMode, getProperty, getValue, getValues, getVariable, hasList, isAltView, setAltView, setCustomField, setRawValue, setValue, setValues, setVariable, store, storeAdditionalPromptData, storeDefaultValues, toString, updateDefaultValue, validateForExecute, validateId
 
- 
 
- 
- 
- 
Constructor Detail- 
NumberElementpublic NumberElement(java.lang.String variableName, UC4ObjectName reference)Creates a new number field.- Parameters:
- variableName- Name of the script variable
- reference- Name of the reference variable
 
 
- 
 - 
Method Detail- 
setQuoteCharacterpublic void setQuoteCharacter(char c) Sets the character for a quote, for example ' or ".- Specified by:
- setQuoteCharacterin interface- PromptInterfaces.QuoteCharacter
- Parameters:
- c- Character
 
 - 
getQuoteCharacterpublic char getQuoteCharacter() Returns the character for a quote.- Specified by:
- getQuoteCharacterin interface- PromptInterfaces.QuoteCharacter
- Returns:
- for example ' or "
 
 - 
getTagNameprotected java.lang.String getTagName() - Specified by:
- getTagNamein class- PromptElement
 
 - 
getTooltippublic java.lang.String getTooltip() Returns the tooltip of this Prompt Element.- Overrides:
- getTooltipin class- PromptElement
- Returns:
- Tooltip
 
 - 
setTooltippublic void setTooltip(java.lang.String tooltip) Sets the tooltip of this Prompt Element.- Overrides:
- setTooltipin class- PromptElement
- Parameters:
- tooltip- Tooltip text
 
 - 
setDataReferencepublic void setDataReference(UC4ObjectName vara) Sets a UC4 VARA Object which contains a list of valid entries for this prompt element.- Specified by:
- setDataReferencein interface- PromptInterfaces.DataReference
- Parameters:
- vara- Name of a Variable Object
 
 - 
getDataReferencepublic UC4ObjectName getDataReference() - Specified by:
- getDataReferencein interface- PromptInterfaces.DataReference
- Returns:
- Name of a Variable Object
 
 - 
setMinValuepublic void setMinValue(java.lang.Integer min) Sets the minimum value.- Specified by:
- setMinValuein interface- PromptInterfaces.Constraints<java.lang.Integer>
- Parameters:
- min- Min value or- nullto disable the lower limit.
 
 - 
getMinValuepublic java.lang.Integer getMinValue() Returns the minimum value.- Specified by:
- getMinValuein interface- PromptInterfaces.Constraints<java.lang.Integer>
- Returns:
- Min value or nullif there is no lower limit.
 
 - 
setMinimumValue@Deprecated public void setMinimumValue(int min) Deprecated.Use setMinValue() insteadSets the minimum value.- Parameters:
- min- Min value or- -1to disable the lower limit.
 
 - 
getMinimumValue@Deprecated public int getMinimumValue() Deprecated.Use getMinValue() insteadReturns the minimum value.- Returns:
- Min value or -1if there is no lower limit.
 
 - 
getCaptionpublic java.lang.String getCaption() - Specified by:
- getCaptionin interface- PromptInterfaces.Caption
- Returns:
- Caption of this prompt element
 
 - 
setCaptionpublic void setCaption(java.lang.String caption) Sets the caption of this prompt element.- Specified by:
- setCaptionin interface- PromptInterfaces.Caption
- Parameters:
- caption- Caption
 
 - 
isLockedpublic boolean isLocked() Returnstrueif this Prompt Element is locked. In this case a user cannot change the default value in the Prompt-Screen.- Specified by:
- isLockedin interface- PromptInterfaces.Locked
- Overrides:
- isLockedin class- PromptElement
- Returns:
- true if locked, false if the user can change the value of the Prompt Element
 
 - 
setLockedpublic void setLocked(boolean locked) Lock or unlocks this element. A user cannot change the default value in the Prompt-Screen if a control is locked.- Specified by:
- setLockedin interface- PromptInterfaces.Locked
- Overrides:
- setLockedin class- PromptElement
- Parameters:
- locked- true if locked, false if the user can change the value of the Prompt Element
 
 - 
hasFocuspublic boolean hasFocus() Returnstrueif the focus is set. The cursor is placed at this control if the value istrue. It may only be defined for one control in the PromptSet. If this flag is defined for several Controls of a PromptSet the last Control that got the flag wins.- Specified by:
- hasFocusin interface- PromptInterfaces.Focus
- Returns:
- true if the cursor should be set in this Prompt Element, false otherwise
 
 - 
setFocuspublic void setFocus(boolean value) Sets the cursor focus: The cursor is placed at this control if the value istrue. It may only be defined for one control in the PromptSet. If this flag is defined for several Controls of a PromptSet the last Control that got the flag wins.- Specified by:
- setFocusin interface- PromptInterfaces.Focus
- Parameters:
- value- true if the cursor should be set in this Prompt Element, false otherwise
 
 - 
setMaxValuepublic void setMaxValue(java.lang.Integer value) Sets the maximum value.- Specified by:
- setMaxValuein interface- PromptInterfaces.Constraints<java.lang.Integer>
- Parameters:
- value- Max value or- nullin order to disable the upper limit.
 
 - 
setMaximumValue@Deprecated public void setMaximumValue(int value) Deprecated.Use setMaxValue() insteadSets the maximum value.- Parameters:
- value- Max value or- -1in order to disable the upper limit.
 
 - 
getMaxValuepublic java.lang.Integer getMaxValue() Returns the maximum value.- Specified by:
- getMaxValuein interface- PromptInterfaces.Constraints<java.lang.Integer>
- Returns:
- Max value or -1if no limit is set.
 
 - 
getMaximumValue@Deprecated public int getMaximumValue() Deprecated.use getMaxValue() insteadReturns the maximum value.- Returns:
- Max value or -1if no limit is set.
 
 - 
listParamprotected java.lang.String listParam() - Overrides:
- listParamin class- PromptElement
 
 
- 
 
-