com.vaadin.flow.component.radiobutton.
Class GeneratedVaadinRadioButton<R extends GeneratedVaadinRadioButton<R>>
- java.lang.Object
-
- com.vaadin.flow.component.Component
-
- com.vaadin.flow.component.radiobutton.GeneratedVaadinRadioButton<R>
-
All Implemented Interfaces:
AttachNotifier
,BlurNotifier<R>
,ClickNotifier<R>
,DetachNotifier
,Focusable<R>
,FocusNotifier<R>
,HasElement
,HasEnabled
,HasStyle
,Serializable
@Tag("vaadin-radio-button") @NpmPackage(value="@vaadin/polymer-legacy-adapter", version="23.1.15") @JsModule("@vaadin/polymer-legacy-adapter/style-modules.js") @JsModule("@vaadin/radio-group/src/vaadin-radio-button.js") public abstract class GeneratedVaadinRadioButton<R extends GeneratedVaadinRadioButton<R>> extends Component implements HasStyle, Focusable<R>, ClickNotifier<R>
Description copied from corresponding location in WebComponent:
<vaadin-radio-button>
is a Web Component for radio buttons.<vaadin-radio-button value="foo">Foo</vaadin-radio-button>
Styling
The following shadow DOM parts are available for styling:
Part name Description radio
The radio button element label
The label content element The following state attributes are available for styling:
Attribute Description Part name disabled
Set when the radio button is disabled. :host focus-ring
Set when the radio button is focused using the keyboard. :host focused
Set when the radio button is focused. :host checked
Set when the radio button is checked. :host See ThemableMixin ? how to apply styles for shadow parts
See Also:
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GeneratedVaadinRadioButton.CheckedChangeEvent<R extends GeneratedVaadinRadioButton<R>>
-
Nested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier
BlurNotifier.BlurEvent<C extends Component>
-
Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier
FocusNotifier.FocusEvent<C extends Component>
-
-
Constructor Summary
Constructors Constructor Description GeneratedVaadinRadioButton()
-
Method Summary
All Methods Modifier and Type Method Description protected Registration
addCheckedChangeListener(ComponentEventListener<GeneratedVaadinRadioButton.CheckedChangeEvent<R>> listener)
Adds a listener for
checked-changed
events fired by the webcomponent.protected String
getNameString()
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
protected String
getValueString()
Description copied from corresponding location in WebComponent:
protected boolean
isAutofocusBoolean()
Description copied from corresponding location in WebComponent:
protected boolean
isCheckedBoolean()
Description copied from corresponding location in WebComponent:
protected boolean
isDisabledBoolean()
Description copied from corresponding location in WebComponent:
protected void
setAutofocus(boolean autofocus)
Description copied from corresponding location in WebComponent:
protected void
setChecked(boolean checked)
Description copied from corresponding location in WebComponent:
protected void
setDisabled(boolean disabled)
Description copied from corresponding location in WebComponent:
protected void
setName(String name)
protected void
setValue(String value)
Description copied from corresponding location in WebComponent:
-
Methods inherited from class com.vaadin.flow.component.Component
addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, scrollIntoView, set, setElement, setId, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListener
-
Methods inherited from interface com.vaadin.flow.component.BlurNotifier
addBlurListener
-
Methods inherited from interface com.vaadin.flow.component.ClickNotifier
addClickListener, addClickShortcut
-
Methods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListener
-
Methods inherited from interface com.vaadin.flow.component.Focusable
addFocusShortcut, blur, focus, getTabIndex, setTabIndex
-
Methods inherited from interface com.vaadin.flow.component.FocusNotifier
addFocusListener
-
Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
-
Methods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled, setEnabled
-
Methods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
-
-
-
-
Method Detail
-
isAutofocusBoolean
protected boolean isAutofocusBoolean()
Description copied from corresponding location in WebComponent:
Specify that this control should have input focus when the page loads.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
autofocus
property from the webcomponent
-
setAutofocus
protected void setAutofocus(boolean autofocus)
Description copied from corresponding location in WebComponent:
Specify that this control should have input focus when the page loads.
Parameters:
autofocus
- the boolean value to set
-
isDisabledBoolean
protected boolean isDisabledBoolean()
Description copied from corresponding location in WebComponent:
If true, the user cannot interact with this element.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
disabled
property from the webcomponent
-
setDisabled
protected void setDisabled(boolean disabled)
Description copied from corresponding location in WebComponent:
If true, the user cannot interact with this element.
Parameters:
disabled
- the boolean value to set
-
getNameString
protected String getNameString()
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
name
property from the webcomponent
-
setName
protected void setName(String name)
Parameters:
name
- the String value to set
-
isCheckedBoolean
@Synchronize(property="checked", value="checked-changed") protected boolean isCheckedBoolean()
Description copied from corresponding location in WebComponent:
True if the radio button is checked.
This property is synchronized automatically from client side when a 'checked-changed' event happens.
Returns:
the
checked
property from the webcomponent
-
setChecked
protected void setChecked(boolean checked)
Description copied from corresponding location in WebComponent:
True if the radio button is checked.
Parameters:
checked
- the boolean value to set
-
getValueString
protected String getValueString()
Description copied from corresponding location in WebComponent:
The value for this element.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
value
property from the webcomponent
-
setValue
protected void setValue(String value)
Description copied from corresponding location in WebComponent:
The value for this element.
Parameters:
value
- the String value to set
-
addCheckedChangeListener
protected Registration addCheckedChangeListener(ComponentEventListener<GeneratedVaadinRadioButton.CheckedChangeEvent<R>> listener)
Adds a listener for
checked-changed
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
-