Package com.uc4.api.prompt
Class RadioGroupElement
- java.lang.Object
-
- com.uc4.api.objects.PromptElement
-
- com.uc4.api.prompt.RadioGroupElement
-
- All Implemented Interfaces:
PromptInterfaces.Caption
,PromptInterfaces.DataReference
,PromptInterfaces.Focus
,PromptInterfaces.ItemList
,PromptInterfaces.Locked
,PromptInterfaces.QuoteCharacter
,PromptInterfaces.XmlKey
,PromptInterfaces.XPath
public class RadioGroupElement extends PromptElement implements PromptInterfaces.Caption, PromptInterfaces.DataReference, PromptInterfaces.Focus, PromptInterfaces.QuoteCharacter, PromptInterfaces.ItemList, PromptInterfaces.Locked, PromptInterfaces.XPath, PromptInterfaces.XmlKey
This class represents a radio group element.
-
-
Field Summary
-
Fields inherited from class com.uc4.api.objects.PromptElement
aliasMap, list, properties
-
-
Constructor Summary
Constructors Constructor Description RadioGroupElement(java.lang.String variableName, UC4ObjectName reference)
Creates a newRadioGroupElement
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getCaption()
UC4ObjectName
getDataReference()
java.util.List<java.lang.String>
getItemList()
When a Prompt is executed (see request TaskPromptSetContent) this method returns a list of valid items.char
getQuoteCharacter()
Returns the character for a quote.protected java.lang.String
getTagName()
java.lang.String
getXmlKey()
Returns the key for XML Variables in the data reference.java.lang.String
getXPath()
Returns the XPath expression if XML variables are used as data reference.boolean
hasFocus()
Returnstrue
if the focus is set.boolean
isLocked()
Returnstrue
if this Prompt Element is locked.void
setCaption(java.lang.String caption)
Sets the caption of this prompt element.void
setDataReference(UC4ObjectName vara)
Sets a VARA Object which contains a list of valid entries for this prompt element.void
setFocus(boolean value)
Sets the cursor focus: The cursor is placed at this control if the value istrue
.void
setLocked(boolean locked)
Lock or unlocks this element.void
setQuoteCharacter(char c)
Sets the character for a quote, for example ' or ".void
setXmlKey(java.lang.String key)
Sets the key in case XML Variables are used as data reference.void
setXPath(java.lang.String xpath)
Sets the XPath expression if XML variables are used as data reference.-
Methods inherited from class com.uc4.api.objects.PromptElement
getCustomField, getMessageInsert, getMessageNumber, getMode, getProperty, getTooltip, getValue, getValues, getVariable, hasList, isAltView, listParam, setAltView, setCustomField, setRawValue, setTooltip, setValue, setValues, setVariable, store, storeAdditionalPromptData, storeDefaultValues, toString, updateDefaultValue, validateForExecute, validateId
-
-
-
-
Constructor Detail
-
RadioGroupElement
public RadioGroupElement(java.lang.String variableName, UC4ObjectName reference)
Creates a newRadioGroupElement
.- Parameters:
variableName
- Name of the script variablereference
- Reference
-
-
Method Detail
-
setQuoteCharacter
public void setQuoteCharacter(char c)
Sets the character for a quote, for example ' or ".- Specified by:
setQuoteCharacter
in interfacePromptInterfaces.QuoteCharacter
- Parameters:
c
- Character
-
getQuoteCharacter
public char getQuoteCharacter()
Returns the character for a quote.- Specified by:
getQuoteCharacter
in interfacePromptInterfaces.QuoteCharacter
- Returns:
- for example ' or "
-
hasFocus
public boolean hasFocus()
Returnstrue
if 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:
hasFocus
in interfacePromptInterfaces.Focus
- Returns:
- true if the cursor should be set in this Prompt Element, false otherwise
-
setFocus
public 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:
setFocus
in interfacePromptInterfaces.Focus
- Parameters:
value
- true if the cursor should be set in this Prompt Element, false otherwise
-
getItemList
public java.util.List<java.lang.String> getItemList()
When a Prompt is executed (see request TaskPromptSetContent) this method returns a list of valid items.- Specified by:
getItemList
in interfacePromptInterfaces.ItemList
- Returns:
- List of items
-
isLocked
public boolean isLocked()
Returnstrue
if this Prompt Element is locked. In this case a user cannot change the default value in the Prompt-Screen.- Specified by:
isLocked
in interfacePromptInterfaces.Locked
- Overrides:
isLocked
in classPromptElement
- Returns:
- true if locked, false if the user can change the value of the Prompt Element
-
setLocked
public 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:
setLocked
in interfacePromptInterfaces.Locked
- Overrides:
setLocked
in classPromptElement
- Parameters:
locked
- true if locked, false if the user can change the value of the Prompt Element
-
getCaption
public java.lang.String getCaption()
- Specified by:
getCaption
in interfacePromptInterfaces.Caption
- Returns:
- Caption of this prompt element
-
setCaption
public void setCaption(java.lang.String caption)
Sets the caption of this prompt element.- Specified by:
setCaption
in interfacePromptInterfaces.Caption
- Parameters:
caption
- Caption
-
setDataReference
public void setDataReference(UC4ObjectName vara)
Sets a VARA Object which contains a list of valid entries for this prompt element.- Specified by:
setDataReference
in interfacePromptInterfaces.DataReference
- Parameters:
vara
- Name of a Variable Object
-
getDataReference
public UC4ObjectName getDataReference()
- Specified by:
getDataReference
in interfacePromptInterfaces.DataReference
- Returns:
- Name of a Variable Object
-
getTagName
protected java.lang.String getTagName()
- Specified by:
getTagName
in classPromptElement
-
setXmlKey
public void setXmlKey(java.lang.String key)
Sets the key in case XML Variables are used as data reference.- Specified by:
setXmlKey
in interfacePromptInterfaces.XmlKey
- Parameters:
key
- Key
-
getXmlKey
public java.lang.String getXmlKey()
Returns the key for XML Variables in the data reference.- Specified by:
getXmlKey
in interfacePromptInterfaces.XmlKey
- Returns:
- Key or an empty String if not set.
-
setXPath
public void setXPath(java.lang.String xpath)
Sets the XPath expression if XML variables are used as data reference.- Specified by:
setXPath
in interfacePromptInterfaces.XPath
- Parameters:
xpath
- XPath/Query expression
-
getXPath
public java.lang.String getXPath()
Returns the XPath expression if XML variables are used as data reference.- Specified by:
getXPath
in interfacePromptInterfaces.XPath
- Returns:
- XPath/Query expression or an empty String if not set.
-
-