@BeanSettings(useXdevCustomizer=true) public class XdevDateTextField extends JTextField implements ClientProperties, FormattedFormularComponent<XdevDateTextField>, DateFormularComponent<XdevDateTextField>, DatePopupOwner, XdevFocusCycleComponent
JTextField
.JTextField
,
ClientProperties
,
FormattedFormularComponent
,
XdevFocusCycleComponent
,
DatePopupOwner
,
Serialized FormJTextField.AccessibleJTextField
JTextComponent.AccessibleJTextComponent, JTextComponent.DropLocation, JTextComponent.KeyBinding
JComponent.AccessibleJComponent
Container.AccessibleAWTContainer
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
FormularComponent.ValueChangeListener
notifyAction
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
DATA_FIELD, FORMULAR_CONDITION_FILTER, FORMULAR_CONDITION_PRECISION, FORMULAR_FILTER_OPERATOR, FORMULAR_SKIP, FORMULAR_VERIFIER, TAG_DATA
DATA_FIELD_SEPARATOR
TAB_INDEX_PROPERTY
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor and Description |
---|
XdevDateTextField()
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(int maxSigns,
TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(String text,
int maxSigns,
TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(String text,
TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(XdevDate value,
int maxSigns,
TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
XdevDateTextField(XdevDate value,
TextFormat textFormat)
Constructor for creating a new instance of a
XdevDateTextField . |
Modifier and Type | Method and Description |
---|---|
void |
addDocumentListener(DocumentListener listener)
Registers the given
DocumentListener to begin receiving
notifications when changes are made to the document. |
void |
addValidator(Validator validator)
Adds a validator to this component
|
void |
addValueChangeListener(FormularComponent.ValueChangeListener l)
Registers a
FormularComponent.ValueChangeListener . |
protected XdevDateDropDownButton |
createDropDownButton()
Creates the drop down button for this text field.
|
XComponent |
createPanel()
Creates the panel which contains this
XdevDateTextField and the
drop down button.This is a convenience methode to build layout constructs. |
Component |
getComponentForDatePopup()
Get this
XdevDateTextField . |
String |
getDataField()
Returns the name of the bound data field of this formular component.
|
XdevDate |
getDate()
Returns the value of this
DateFormularComponent as
XdevDate . |
XdevDate |
getDate(XdevDate defaultValue)
Returns the value of this
DateFormularComponent as
XdevDate . |
DatePopupCustomizer |
getDatePopupCustomizer()
Gets the
DatePopupCustomizer of this XdevDateTextField . |
XdevDateDropDownButton |
getDropDownButton()
Gets the
XdevDateDropDownButton of this XdevDateTextField
. |
Operator |
getFilterOperator()
Returns the operator used in
Formular.createCondition(String) |
FocusGainedBehavior |
getFocusGainedBehavior()
Returns the
FocusGainedBehavior of this TextComponent. |
String |
getFormularName()
Returns the name of the component in the formular context.
|
Object |
getFormularValue()
Returns the value of the component.
|
int |
getMaxSignCount()
Returns the max sign count of this
XdevDateTextField . |
Dimension |
getPreferredSize() |
String |
getSelectedText()
Returns the selected text contained in this
XdevDateTextField . |
int |
getTabIndex()
Returns the tabindex assigned to this component.
|
TextChangedBehavior |
getTextChangedBehavior()
Return the
TextChangedBehavior of this TextComponent |
TextFormat |
getTextFormat()
Returns the associated
TextFormat of this component. |
Validator[] |
getValidators()
Returns all validators of this component.
|
boolean |
hasStateChanged()
Checks if the component's state since the last call of
FormularComponent.saveState() has changed. |
void |
hideDatePopup() |
void |
insertText(String text)
Inserts a
String into this XdevDateTextField . |
boolean |
isDatePopupVisible() |
boolean |
isDropDownButtonVisible()
Returns
true if the drop down button is visible,
false otherwise |
boolean |
isMultiSelect()
Returns whether the component supports multi selection or not.
|
boolean |
isReadOnly()
Determines whether this component is only used to display values.
|
void |
removeDocumentListener(DocumentListener listener)
Unregisters the given
DocumentListener from the notification list
so it will no longer receive change updates. |
void |
removeValidator(Validator validator)
Removes a validator from this component
|
void |
restoreState()
Restores the internally saved state of the component.
|
void |
saveState()
Saves the state of the component internally.
|
void |
setCursor(Cursor cursor) |
void |
setDataField(String dataField)
Sets the name of the bound data field of this formular component.
|
void |
setDate(XdevDate date)
Sets the date of this
DateFormularComponent . |
void |
setDatePopupCustomizer(DatePopupCustomizer datePopupCustomizer)
Sets the
DatePopupCustomizer of this XdevDateTextField . |
void |
setDatePopupVisible(boolean visible)
Shows or hides the date popup.
|
void |
setDropDownButtonVisible(boolean b)
Shows or hides the drop down button.
|
void |
setEnabled(boolean enabled) |
void |
setFilterOperator(Operator filterOperator)
Sets the filter operator used in
Formular.createCondition(String) |
void |
setFocusGainedBehavior(FocusGainedBehavior focusGainedBehavior)
Sets the new
FocusGainedBehavior for this TextComponent. |
void |
setFormularValue(VirtualTable vt,
int col,
Object value)
Deprecated.
|
void |
setFormularValue(VirtualTable vt,
Map<String,Object> record)
Sets the value of the component, taking the value(s) of the record
according to
FormularComponent.getDataField() . |
void |
setMaxSignCount(int maxSignCount)
Sets the max sign count of this
XdevDateTextField . |
void |
setReadOnly(boolean readOnly)
Sets if this form component is only used to display values.
|
void |
setTabIndex(int tabIndex)
Sets the tabindex of this component.
|
void |
setText(String t) |
void |
setTextChangedBehavior(TextChangedBehavior textChangedBehavior)
Sets the new
TextChangedBehavior for this TextComponent. |
void |
setTextFormat(TextFormat textFormat)
Sets the new
TextFormat which is used to format the displayed
value of this component. |
void |
setValue(Object value)
Set the
value in this XdevDateTextField as text. |
void |
setVisible(boolean visible) |
String |
toString() |
void |
validateState()
Calls
Validator.validate(Object) of all registered
Validator s. |
void |
validateState(Validation validation)
Calls
Validator.validate(Object) of all registered
Validator s. |
boolean |
verify()
Returns whether the component's value adheres all set constraints.
|
actionPropertyChanged, addActionListener, configurePropertiesFromAction, createActionPropertyChangeListener, createDefaultModel, fireActionPerformed, getAccessibleContext, getAction, getActionListeners, getActions, getColumns, getColumnWidth, getHorizontalAlignment, getHorizontalVisibility, getScrollOffset, getUIClassID, isValidateRoot, paramString, postActionEvent, removeActionListener, scrollRectToVisible, setAction, setActionCommand, setColumns, setDocument, setFont, setHorizontalAlignment, setScrollOffset
addCaretListener, addInputMethodListener, addKeymap, copy, cut, fireCaretUpdate, getCaret, getCaretColor, getCaretListeners, getCaretPosition, getDisabledTextColor, getDocument, getDragEnabled, getDropLocation, getDropMode, getFocusAccelerator, getHighlighter, getInputMethodRequests, getKeymap, getKeymap, getMargin, getNavigationFilter, getPreferredScrollableViewportSize, getPrintable, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getSelectedTextColor, getSelectionColor, getSelectionEnd, getSelectionStart, getText, getText, getToolTipText, getUI, isEditable, loadKeymap, modelToView, moveCaretPosition, paste, print, print, print, processInputMethodEvent, read, removeCaretListener, removeKeymap, removeNotify, replaceSelection, restoreComposedText, saveComposedText, select, selectAll, setCaret, setCaretColor, setCaretPosition, setComponentOrientation, setDisabledTextColor, setDragEnabled, setDropMode, setEditable, setFocusAccelerator, setHighlighter, setKeymap, setMargin, setNavigationFilter, setSelectedTextColor, setSelectionColor, setSelectionEnd, setSelectionStart, setUI, updateUI, viewToModel, write
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, unregisterKeyboardAction, update
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycle
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getClientProperty, isEnabled, isVisible, putClientProperty
getText
public XdevDateTextField()
XdevDateTextField
.
Initialized with default TextFormat
.public XdevDateTextField(TextFormat textFormat)
XdevDateTextField
.
Initialized with the specified textFormat
.textFormat
- the TextFormat
to format the display value,
null
if nonepublic XdevDateTextField(String text, TextFormat textFormat)
XdevDateTextField
.
Initialized with the specified text
, textFormat
and the default maxSigns
of 100
.text
- the text to be displayed, null
if nonetextFormat
- the TextFormat
to format the display value,
null
if nonepublic XdevDateTextField(int maxSigns, TextFormat textFormat) throws IllegalArgumentException
XdevDateTextField
.
Initialized with the specified maxSigns
and
textFormat
.maxSigns
- a int
to determine the max signs of the
MaxSignDocument
textFormat
- the TextFormat
to format the display value,
null
if noneIllegalArgumentException
- if the maxSigns
is <= 0public XdevDateTextField(String text, int maxSigns, TextFormat textFormat) throws IllegalArgumentException
XdevDateTextField
.
Initialized with the specified text
, maxSigns
and textFormat
.text
- the text to be displayed, null
if nonemaxSigns
- a int
to determine the max signs of the
MaxSignDocument
textFormat
- the TextFormat
to format the display value,
null
if noneIllegalArgumentException
- if the maxSigns
is <= 0public XdevDateTextField(XdevDate value, TextFormat textFormat)
XdevDateTextField
.
Initialized with the specified value
and
textFormat
.value
- the initial valuetextFormat
- the TextFormat
to format the display value,
null
if nonepublic XdevDateTextField(XdevDate value, int maxSigns, TextFormat textFormat) throws IllegalArgumentException
XdevDateTextField
.
Initialized with the specified value
, maxSigns
and textFormat
.value
- the initial valuemaxSigns
- a int
to determine the max signs of the
MaxSignDocument
textFormat
- the TextFormat
to format the display value,
null
if noneIllegalArgumentException
- if the maxSigns
is <= 0public FocusGainedBehavior getFocusGainedBehavior()
FocusGainedBehavior
of this TextComponent.FocusGainedBehavior
of this TextComponentpublic void setFocusGainedBehavior(FocusGainedBehavior focusGainedBehavior)
FocusGainedBehavior
for this TextComponent.focusGainedBehavior
- the new FocusGainedBehavior
{@link
- IllegalArgumentException} if
focusGainedBehavior
is null
public TextChangedBehavior getTextChangedBehavior()
TextChangedBehavior
of this TextComponentTextChangedBehavior
of this TextComponentpublic void setTextChangedBehavior(TextChangedBehavior textChangedBehavior)
TextChangedBehavior
for this TextComponent.textChangedBehavior
- the new TextChangedBehavior
{@link
- IllegalArgumentException} if
textChangedBehavior
is null
public void setText(String t)
setText
in interface DatePopupOwner
setText
in class JTextComponent
UIUtils.scrollToStart(javax.swing.JComponent)
public Dimension getPreferredSize()
getPreferredSize
in class JTextField
protected XdevDateDropDownButton createDropDownButton()
Overwrite this method if you want to use your own drop down button.
public XdevDateDropDownButton getDropDownButton()
XdevDateDropDownButton
of this XdevDateTextField
.XdevDateDropDownButton
of this
XdevDateTextField
public void setDropDownButtonVisible(boolean b)
b
- true
if the button should be shown,
false
if the button should be hiddenpublic boolean isDropDownButtonVisible()
true
if the drop down button is visible,
false
otherwisepublic XComponent createPanel()
XdevDateTextField
and the
drop down button.XdevDateTextField
and the drop
down buttonpublic void setDatePopupCustomizer(DatePopupCustomizer datePopupCustomizer)
DatePopupCustomizer
of this XdevDateTextField
.datePopupCustomizer
- a DatePopupCustomizer
to be set.public DatePopupCustomizer getDatePopupCustomizer()
DatePopupCustomizer
of this XdevDateTextField
.getDatePopupCustomizer
in interface DatePopupOwner
DatePopupCustomizer
of this XdevDateTextField
public void addDocumentListener(DocumentListener listener)
DocumentListener
to begin receiving
notifications when changes are made to the document.listener
- the DocumentListener
to registerDocument.addDocumentListener(DocumentListener)
public void removeDocumentListener(DocumentListener listener)
DocumentListener
from the notification list
so it will no longer receive change updates.listener
- the observer to registeraddDocumentListener(DocumentListener)
public int getMaxSignCount()
XdevDateTextField
.XdevDateTextField
, -1 if the
Document
is not an instance of MaxSignDocument
.MaxSignDocument
public void setMaxSignCount(int maxSignCount)
XdevDateTextField
.maxSignCount
- the max sign count of this XdevDateTextField
public String getFormularName()
getFormularName
in interface FormularComponent<XdevDateTextField>
public void setDataField(String dataField)
setDataField
in interface FormularComponent<XdevDateTextField>
dataField
- the new bound data fieldpublic String getDataField()
getDataField
in interface FormularComponent<XdevDateTextField>
@Deprecated public final void setFormularValue(VirtualTable vt, int col, Object value)
value
. The value is formatted using the column format of the
provided VirtualTable
and columnIndex
.setFormularValue
in interface FormularComponent<XdevDateTextField>
vt
- VirtualTable
to use the format fromcol
- of the column to use the format fromvalue
- value to setpublic void setFormularValue(VirtualTable vt, Map<String,Object> record)
FormularComponent.getDataField()
.setFormularValue
in interface FormularComponent<XdevDateTextField>
vt
- the underlying virtual tablerecord
- the data <column,value>public Object getFormularValue()
getFormularValue
in interface FormularComponent<XdevDateTextField>
public void saveState()
A saved state can be restored using FormularComponent.restoreState()
.
saveState
in interface FormularComponent<XdevDateTextField>
public void restoreState()
The state of the component can be saved using FormularComponent.saveState()
.
restoreState
in interface FormularComponent<XdevDateTextField>
public boolean hasStateChanged()
FormularComponent.saveState()
has changed.hasStateChanged
in interface FormularComponent<XdevDateTextField>
true
if the component's state has changed,
false
otherwisepublic void addValueChangeListener(FormularComponent.ValueChangeListener l)
FormularComponent.ValueChangeListener
.addValueChangeListener
in interface FormularComponent<XdevDateTextField>
l
- the listener to registerpublic boolean isMultiSelect()
A component that supports multi selection can have more than one selected item / value.
isMultiSelect
in interface FormularComponent<XdevDateTextField>
true
if the component supports multi
selection, false
otherwise.public boolean verify()
This is a alternative method for FormularComponent.validateState()
, but this
method returns a boolean depending on the validation's result and doesn't
throw an ValidationException
.
verify
in interface FormularComponent<XdevDateTextField>
true
if the value of the component adheres all set
constraints; otherwise false
.public void addValidator(Validator validator)
addValidator
in interface FormularComponent<XdevDateTextField>
validator
- the validator to addFormularComponent.validateState()
public void removeValidator(Validator validator)
removeValidator
in interface FormularComponent<XdevDateTextField>
validator
- the validator to removeFormularComponent.validateState()
public Validator[] getValidators()
If no validator is present an empty array is returned.
getValidators
in interface FormularComponent<XdevDateTextField>
public void validateState() throws ValidationException
Validator.validate(Object)
of all registered
Validator
s.validateState
in interface FormularComponent<XdevDateTextField>
ValidationException
FormularComponent.verify()
public void validateState(Validation validation) throws ValidationException
Validator.validate(Object)
of all registered
Validator
s.
Every ValidationException
is recorded in the
validation
object, and if
Validation.continueValidation(ValidationException)
returns
false
this exception is re-thrown by this method.
validateState
in interface FormularComponent<XdevDateTextField>
validation
- the validation process objectValidationException
FormularComponent.verify()
public void setFilterOperator(Operator filterOperator)
Formular.createCondition(String)
setFilterOperator
in interface FormularComponent<XdevDateTextField>
filterOperator
- the new filter operatorpublic Operator getFilterOperator()
Formular.createCondition(String)
getFilterOperator
in interface FormularComponent<XdevDateTextField>
public void setReadOnly(boolean readOnly)
setReadOnly
in interface FormularComponent<XdevDateTextField>
readOnly
- true
to only display valuespublic boolean isReadOnly()
isReadOnly
in interface FormularComponent<XdevDateTextField>
true
if this component is only used to display
values.public void setVisible(boolean visible)
setVisible
in class JComponent
public void setEnabled(boolean enabled)
setEnabled
in class JComponent
public void setDatePopupVisible(boolean visible)
visible
- true
if the popup should be shown,
false
if the popup should be hiddenpublic boolean isDatePopupVisible()
public TextFormat getTextFormat()
TextFormat
of this component.getTextFormat
in interface DatePopupOwner
getTextFormat
in interface FormattedFormularComponent<XdevDateTextField>
TextFormat
of this componentpublic void setTextFormat(TextFormat textFormat)
TextFormat
which is used to format the displayed
value of this component.setTextFormat
in interface FormattedFormularComponent<XdevDateTextField>
textFormat
- the new TextFormat
public Component getComponentForDatePopup()
XdevDateTextField
.getComponentForDatePopup
in interface DatePopupOwner
XdevDateTextField
as Component
public void hideDatePopup()
hideDatePopup
in interface DatePopupOwner
public String getSelectedText() throws IllegalArgumentException
XdevDateTextField
. If
the selection is null
or the document empty, returns a empty
String
.getSelectedText
in class JTextComponent
String
IllegalArgumentException
- if the selection doesn't have a valid mapping into the
document for some reasonsetText(java.lang.String)
,
JTextComponent.getSelectedText()
public void insertText(String text)
String
into this XdevDateTextField
.text
- the String
to insertDocument.insertString(int, String, javax.swing.text.AttributeSet)
public XdevDate getDate() throws DateFormatException
DateFormularComponent
as
XdevDate
.getDate
in interface DateFormularComponent<XdevDateTextField>
DateFormularComponent
as
XdevDate
.DateFormatException
- if the value of this DateFormularComponent
can not be
converted.DateFormularComponent.getDate(XdevDate)
,
TextFormat.parseDate(String)
public XdevDate getDate(XdevDate defaultValue)
DateFormularComponent
as
XdevDate
. If the internal value can not be converted into a
XdevDate
, the defaultValue
is returned.getDate
in interface DateFormularComponent<XdevDateTextField>
defaultValue
- the default XdevDate
DateFormularComponent
. If the internal
value can not be converted into a XdevDate
, the
defaultValue
is returned.DateFormularComponent.getDate()
public void setDate(XdevDate date)
DateFormularComponent
.setDate
in interface DateFormularComponent<XdevDateTextField>
date
- the new datepublic void setValue(Object value)
value
- the display valuesetText(String)
public String toString() throws NullPointerException
toString
in class Component
NullPointerException
public int getTabIndex()
getTabIndex
in interface XdevFocusCycleComponent
public void setTabIndex(int tabIndex)
To exclude this component from the focus cycle set tabindex to -1.
setTabIndex
in interface XdevFocusCycleComponent
tabIndex
- to be setCopyright © 2003–2021 XDEV Software. All rights reserved.