com.vaadin.ui
Class TextField
java.lang.Object
com.vaadin.terminal.AbstractClientConnector
com.vaadin.ui.AbstractComponent
com.vaadin.ui.AbstractField<String>
com.vaadin.ui.AbstractTextField
com.vaadin.ui.TextField
- All Implemented Interfaces:
- Buffered, BufferedValidatable, Property<String>, Property.Editor, Property.ReadOnlyStatusChangeListener, Property.ReadOnlyStatusChangeNotifier, Property.ValueChangeListener, Property.ValueChangeNotifier, Property.Viewer, Validatable, Action.ShortcutNotifier, FieldEvents.BlurNotifier, FieldEvents.FocusNotifier, FieldEvents.TextChangeNotifier, MethodEventSource, Connector, ClientConnector, RpcTarget, Sizeable, Vaadin6Component, VariableOwner, Component, Component.Focusable, Field<String>, Serializable, EventListener
public class TextField
- extends AbstractTextField
A text editor component that can be bound to any bindable Property. The text
editor supports both multiline and single line modes, default is one-line
mode.
Since TextField
extends AbstractField
it implements
the Buffered
interface. A TextField
is
in write-through mode by default, so
AbstractField.setWriteThrough(boolean)
must be called
to enable buffering.
- Since:
- 3.0
- Version:
- 7.0.0.alpha3
- Author:
- Vaadin Ltd.
- See Also:
- Serialized Form
Constructor Summary |
TextField()
Constructs an empty TextField with no caption. |
TextField(Property dataSource)
Constructs a new TextField that's bound to the specified
Property and has no caption. |
TextField(String caption)
Constructs an empty TextField with given caption. |
TextField(String caption,
Property dataSource)
Constructs a new TextField that's bound to the specified
Property and has the given caption String . |
TextField(String caption,
String value)
Constructs a new TextField with the given caption and
initial text contents. |
Methods inherited from class com.vaadin.ui.AbstractTextField |
addListener, addListener, addListener, changeVariables, getColumns, getCursorPosition, getInputPrompt, getMaxLength, getNullRepresentation, getState, getTextChangeEventMode, getTextChangeTimeout, getType, isEmpty, isNullSettingAllowed, paintContent, removeListener, removeListener, removeListener, selectAll, setColumns, setCursorPosition, setInputPrompt, setInternalValue, setMaxLength, setNullRepresentation, setNullSettingAllowed, setSelectionRange, setTextChangeEventMode, setTextChangeTimeout, setValue, updateState |
Methods inherited from class com.vaadin.ui.AbstractField |
addListener, addListener, addValidator, attach, commit, detach, discard, fireReadOnlyStatusChange, fireValueChange, focus, getConversionError, getConversionError, getConvertedValue, getConverter, getCurrentBufferedSourceException, getErrorMessage, getInternalValue, getPropertyDataSource, getRequiredError, getTabIndex, getValidators, getValue, isBuffered, isInvalidAllowed, isInvalidCommitted, isModified, isReadOnly, isReadThrough, isRequired, isValid, isValidationVisible, isWriteThrough, readOnlyStatusChange, removeAllValidators, removeListener, removeListener, removeValidator, setBuffered, setConversionError, setConvertedValue, setConverter, setConverter, setCurrentBufferedSourceException, setInvalidAllowed, setInvalidCommitted, setPropertyDataSource, setReadOnly, setReadThrough, setRequired, setRequiredError, setTabIndex, setValidationVisible, setValue, setWriteThrough, shouldHideErrors, toString, validate, validate, valueChange |
Methods inherited from class com.vaadin.ui.AbstractComponent |
addListener, addListener, addListener, addListener, addShortcutListener, addStyleName, findAncestor, fireComponentErrorEvent, fireComponentEvent, fireEvent, getActionManager, getApplication, getCaption, getComponentError, getData, getDebugId, getDescription, getErrorHandler, getHeight, getHeightUnits, getIcon, getListeners, getLocale, getParent, getRoot, getStyle, getStyleName, getWidth, getWidthUnits, handleError, hasListeners, isConnectorEnabled, isEnabled, isImmediate, isVisible, removeListener, removeListener, removeListener, removeListener, removeListener, removeShortcutListener, removeStyleName, requestRepaint, setCaption, setComponentError, setData, setDebugId, setDescription, setEnabled, setErrorHandler, setHeight, setHeight, setIcon, setImmediate, setLocale, setParent, setSizeFull, setSizeUndefined, setStyle, setStyleName, setVisible, setWidth, setWidth |
Methods inherited from class com.vaadin.terminal.AbstractClientConnector |
addExtension, addMethodInvocationToQueue, createState, getAllChildrenIterable, getConnectorId, getExtensions, getRpcManager, getRpcProxy, getStateType, registerRpc, registerRpc, removeExtension, requestRepaintAll, retrievePendingRpcCalls |
Methods inherited from interface com.vaadin.ui.Component |
addListener, addStyleName, attach, getApplication, getCaption, getDebugId, getIcon, getLocale, getParent, getRoot, getStyleName, isEnabled, isReadOnly, isVisible, removeListener, removeStyleName, setCaption, setDebugId, setEnabled, setIcon, setReadOnly, setStyleName, setVisible |
TextField
public TextField()
- Constructs an empty
TextField
with no caption.
TextField
public TextField(String caption)
- Constructs an empty
TextField
with given caption.
- Parameters:
caption
- the caption String
for the editor.
TextField
public TextField(Property dataSource)
- Constructs a new
TextField
that's bound to the specified
Property
and has no caption.
- Parameters:
dataSource
- the Property to be edited with this editor.
TextField
public TextField(String caption,
Property dataSource)
- Constructs a new
TextField
that's bound to the specified
Property
and has the given caption String
.
- Parameters:
caption
- the caption String
for the editor.dataSource
- the Property to be edited with this editor.
TextField
public TextField(String caption,
String value)
- Constructs a new
TextField
with the given caption and
initial text contents. The editor constructed this way will not be bound
to a Property unless
Property.Viewer.setPropertyDataSource(Property)
is called to bind it.
- Parameters:
caption
- the caption String
for the editor.value
- the initial text content of the editor.
Copyright © 2000-2011 Vaadin Ltd. All Rights Reserved.