Package overit.geocall.basic.ui.control
Class InputRadio
java.lang.Object
overit.geocall.platform.ui.UINode
overit.geocall.ui.Component
overit.geocall.ui.Control
overit.geocall.basic.ui.control.Input
overit.geocall.basic.ui.control.InputRadio
- All Implemented Interfaces:
Serializable,overit.geocall.marks.MethodExposer,overit.geocall.marks.NameExposer,Arrangeable,Badgeable,ValueValidator,Identified,Tool,overit.geocall.ux.configurability.UIConfigurable,overit.geocall.ux.edm.ModelConfigurable
- Direct Known Subclasses:
InputCheckBoxes
This class extends
Input and implements the graphic user interface element that render a classic radio button.
It is usually used in combination with other radio buttons that describes a set of related options. Only one radio button
in a given group can be selected at the same time.- See Also:
- GCApi:
- component
-
Nested Class Summary
Nested classes/interfaces inherited from class overit.geocall.ui.Component
Component.Configurable, Component.ConfigurableAttribute, Component.ConfigurableAttributes, Component.FilterCriteria, Component.Registry -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected Stringprotected Stringprotected intprotected intprotected intprotected booleanprotected intprotected booleanprotected static final StringFields inherited from class overit.geocall.basic.ui.control.Input
_autofocus, _da, _dao, _dao0, _defaultFocus, _event, _eventicon, _eventmsg, _eventparam, _eventprompt, _eventsnumber, _eventtitle, _ff, _fullSize, _hidden, _hinter, _hints, _hintsCache, _key, _label2, _letterCase, _maxlength, _msg, _msgCampoObbligatorio, _msgErroreCampo, _notnull, _numeric, _placeholder, _query, _roevent, _size, _value, autocomplete, configuredFullSize, configuredNotNull, configuredSize, FILTER_CRITERION_ATTRIBUTE, filterCriteria, FULL_SIZE_ATTRIBUTE, NOT_NULL_ATTRIBUTE, promptEmpty, SIZE_ATTRIBUTEFields inherited from class overit.geocall.ui.Control
_blank, _cleaner, _dblink, _enabled, _ro, _title, altEventIconsList, altIcon, ariaDescription, ariaLabel, badge, badgeformat, FILTER_PREFIXES, LABEL_ATTRIBUTE, LABEL_IN_LINE_ATTRIBUTE, STATE_BLANK, STATE_NORMAL, STATE_RO, STATE_ROBLANKFields inherited from class overit.geocall.ui.Component
_basic, _childrenContainers, _currentId, _gridalign, _gridcols, _gridrows, _gridvalign, _iconElement, _id, _keylabel, _label, _layoutName, _name, _parentContainer, _registryName, _shortcut, _tabindex, _transformations, _valuesContainer, aliasField, BR, configHidden, configuredLabel, configuredLabelInLine, defaultHidden, ELEMENT_BR, ELEMENT_NULL, entityContainer, entityName, extendedField, fullHeight, important, labelInLine, layoutLabel, PIXEL_IMG, safeInlineService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidEvery component can add a script to the StringBuilder, script executed when the component is displayed.protected voidcreateColumns(int iCol, int iElementXCol, List v, org.apache.ecs.html.TR[] tr, EntitySet es) org.apache.ecs.ElementgetContentHtml(Object generationhandle, EntitySet es) Implements the interfaceArrangeable.protected org.apache.ecs.Elementprotected org.apache.ecs.Elementorg.apache.ecs.ElementgetDescriptionHtml(Object generationhandle, EntitySet es) Implements the interfaceArrangeable.Implements the interfaceArrangeableorg.apache.ecs.ElementgetHiddenHtml(Object generationhandle, EntitySet es) Implements the interfaceArrangeable.org.apache.ecs.ElementReturns the html of the Input elementprotected org.apache.ecs.ElementgetHtmlTable(EntitySet es, org.apache.ecs.Element label) protected org.apache.ecs.html.Inputprotected Stringprotected org.apache.ecs.ElementgetVisibleDescriptionHtml(Object generationhandle, EntitySet es) protected booleanisSelected(String sCurrentValue, boolean oldSelection, String sName) protected Stringprotected voidpublishValue(Object publishedValue) voidSets the name of an event associated to the field and triggered when the user changes its value.voidSet the value that will be passed to theHashGetteras a parameter when the autoevent is triggered.voidSets the number of columns used to organize the radio buttonsvoidDefines if the button is the one selected or not.voidDefines the type of the field values.protected voidsetupAccessKeyTooltipAndValidationOnInput(org.apache.ecs.html.Input i, int iCol, int iRow, String sTitle, EntitySet es) protected voidsetupInput(org.apache.ecs.html.Input i, String style, String sValue, boolean disabled, Object[] obj) voidSets the arranging method used to position the buttons.protected booleanprotected voidvoidvalidateConcreteValue(String name, Object value, boolean strong, Map arriving) Methods inherited from class overit.geocall.basic.ui.control.Input
addEventButtons, addHint, addHint, addHintsButton, ajaxQuery, connect, control, getClassStyle, getConfigurableProperties, getDefaultValue, getFilterCriteriaToRemove, getFullSize, getHIDDEN, getHintsEventButton, getHintsFieldName, getInsideEventButton, getInsideEventButton, getLetterCase, getNOTNULL, getSize, isImportant, isNotNull, isValueIgnoredByCriterion, prepareValue, queryHints, registerValidators, setAUTOCOMPLETE, setAUTOFOCUS, setConfiguredProperty, setDA, setDAO, setDAO0, setDEFAULTFOCUS, setEVENT, setEVENTMSG, setEVENTPARAM, setEVENTPROMPT, setEVENTTITLE, setFILTERCRITERIA, setFULLSIZE, setHIDDEN, setHints, setHINTS, setHINTSCACHE, setICON, setIMPORTANT, setKEY, setLABEL2, setLETTERCASE, setMAXLENGTH, setModelProperties, setMSG, setNAME, setNOTNULL, setNUMERIC, setPARAM, setPLACEHOLDER, setPROMPT, setPROMPTEMPTY, setQUERY, setROEVENT, setSIZE, setup, setupAutocomplete, setVALUE, validateChangingValue, validateNotNull, validateUnchangingValue, validateValueMethods inherited from class overit.geocall.ui.Control
avoidNull, clean, getBadgeFormat, getBadgeValue, getBLANK, getCleaner, getDAValues, getDBLINK, getKEYLABEL, getLABEL, getRO, getState, getTITLE, getValues, getWM, isEnabled, isEnabledBasedOnFunction, isFunctionEnabled, isRoBasedOnFunction, nameWithNoFilterPrefix, setALTEVENTICON, setALTICON, setARIADESCRIPTION, setARIALABEL, setBADGEFORMAT, setBADGEVALUE, setBLANK, setCLEANER, setDBLINK, setENABLED, setFUNCTION, setRO, setTitle, setTITLEMethods inherited from class overit.geocall.ui.Component
adapt, appendAttribute, buildSetupScript, calcKeyLabel, calcLabel, calcShortcut, canBeConfigured, changed, clearConfiguredProperties, componentIterator, componentSize, containerIterator, createAjaxFrame, deprecate, fillSetupScript, generateFlexableFullHeightContainer, generateId, getBASIC, getBoolean, getBoolean, getChildrenComponents, getChildrenContainers, getDefaultLabel, getDefaultLayoutLabel, getEntityContainer, getEntityName, getFullHeight, getGridAlign, getGridCols, getGridRows, getGridVAlign, getHtmlLabel, getHtmlLabel, getIcon, getId, getIdentity, getint, getLayoutLabel, getLayoutName, getNAME, getParentComponent, getParentContainer, getPublishedChildrenList, getRegistryName, getSHORTCUT, getTabIndex, getTeacher, getValuesContainer, getWindow, initChilds, isActivable, isActive, isAliasField, isConfigHidden, isDefaultHidden, isExtendedField, isLabelInLine, onInit, setActivable, setActive, setAliasField, setBASIC, setConfigHidden, setDEFAULTHIDDEN, setEntityName, setExtendedField, setFULLHEIGHT, setGRIDALIGN, setGRIDCOLS, setGRIDROWS, setGRIDVALIGN, setIdentity, setLabel, setLABEL, setLABELINLINE, setLAYOUTLABEL, setLAYOUTNAME, setREGISTRYNAME, setTooltip, setValuesContainer, stringForJs, tabIndexerMethods inherited from class overit.geocall.platform.ui.UINode
addChild, addChildText, getChildren, getNodeId, getParent, getRoot, getSchema, setNodeId, setParent, setSchemaMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface overit.geocall.ui.Badgeable
badgeFormat, makeBadgedIcon
-
Field Details
-
BLANK_SPACE
- See Also:
-
_type
protected int _type -
_selected
protected boolean _selected -
_iColumns
protected int _iColumns -
_iCountRow
protected int _iCountRow -
_autoevent
-
_autoeventparam
-
_vertical
protected boolean _vertical -
_firstInputId
-
_lastcalltotalelements
protected int _lastcalltotalelements
-
-
Constructor Details
-
InputRadio
public InputRadio()Creates an InputRadio
-
-
Method Details
-
setAUTOEVENT
Sets the name of an event associated to the field and triggered when the user changes its value. By setting an autoevent, a form submit will be automatically performed when the field loses the focus.- Parameters:
s- The name of the event triggered when the user changes the field value
-
setAUTOEVENTPARAM
Set the value that will be passed to theHashGetteras a parameter when the autoevent is triggered. The key of the value into HashGetter will be"param"- Parameters:
s- Value passed to theHashGetteras a parameter
-
setSELECTED
Defines if the button is the one selected or not.- Parameters:
s- A string that represents a boolean value ("true" or "1", "false" or "0").
If the string is not recognized as a boolean value, it will be used the default value, that isfalse
-
setVERTICAL
Sets the arranging method used to position the buttons.- Parameters:
s-true, that is the default value, to arrange the buttons vertically (from top to bottom);falseto arrange the buttons horizontally (from left to right).
If the string value is not recognized as a boolean value, the default value will be used.
-
setCOLS
Sets the number of columns used to organize the radio buttons- Parameters:
s- The number of columns. The default value is 1.
-
setTYPE
Defines the type of the field values.- Parameters:
s- Accepted values are: "long" (that is also the default one), to state that the values are Long values; "string" to state that the values are String values.
-
getDescriptionHtml
Description copied from class:InputImplements the interfaceArrangeable. It returns the html code that represents the component description i.e. the formatted label of the field- Specified by:
getDescriptionHtmlin interfaceArrangeable- Overrides:
getDescriptionHtmlin classInput- Parameters:
generationhandle- The handle of the generationes- TheEntitySetto which the element belongs- Returns:
- The html code of the label, or null if the field don't have it or is hidden
-
getVisibleDescriptionHtml
- Overrides:
getVisibleDescriptionHtmlin classInput
-
getContentHtml
Description copied from class:InputImplements the interfaceArrangeable. It returns the html code that represents the active part of the input field, i.e. the field and the validation scripts- Specified by:
getContentHtmlin interfaceArrangeable- Overrides:
getContentHtmlin classInput- Parameters:
generationhandle- The handle of the generationes- TheEntitySetto which the element belongs- Returns:
- The html code of the input field or null if the field don't have a graphical representation
-
getHiddenHtml
Description copied from class:InputImplements the interfaceArrangeable. It returns the hidden but active html part of an hidden input field.- Specified by:
getHiddenHtmlin interfaceArrangeable- Overrides:
getHiddenHtmlin classInput- Parameters:
generationhandle- The handle of the generationes- TheEntitySetto which the element belongs- Returns:
- The html code of the hidden part of the field or null if the field is visible.
-
getGenerationHandle
Description copied from class:InputImplements the interfaceArrangeable- Specified by:
getGenerationHandlein interfaceArrangeable- Overrides:
getGenerationHandlein classInput- Returns:
- null
-
getHtml
Description copied from class:InputReturns the html of the Input element -
getControlElement
protected org.apache.ecs.Element getControlElement() -
getControlButtons
-
getHtmlTable
-
createColumns
-
getStyle
-
setupAccessKeyTooltipAndValidationOnInput
-
setupInput
-
publishValue
-
validate
-
prepareName
- Overrides:
prepareNamein classInput
-
getInput
-
typeString
protected boolean typeString() -
isSelected
-
buildDisplayScript
Description copied from class:InputEvery component can add a script to the StringBuilder, script executed when the component is displayed. The method add the script that controls the focus on the input field.- Overrides:
buildDisplayScriptin classInput- Parameters:
sb- The StringBuilder on which we want to add the script
-
validateConcreteValue
public void validateConcreteValue(String name, Object value, boolean strong, Map arriving) throws ValidationException - Overrides:
validateConcreteValuein classInput- Throws:
ValidationException
-