|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.tentackle.ui.FormPanel
org.tentackle.ui.FormComponentPanel
org.tentackle.ui.FormFieldComponentPanel
org.tentackle.ui.FormCalendarField
public class FormCalendarField
A date field with a calendar button.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
static int |
SHOW_AUTO
show only date (default) |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
FormCalendarField()
Creates a calendar field. |
|
| Method Summary | |
|---|---|
Date |
getDate()
Gets the java.sql.Date. |
Date |
getFormValue()
Retrieves the value from this component. The method is used to update the data if the view has changed because the user edited it. |
Date |
getReferenceDate()
Gets the reference date. |
Time |
getTime()
Gets the java.sql.Time. |
int |
getTimeMode()
Gets the time mode. One of FormCalendar.SHOW_... |
Timestamp |
getTimestamp()
Gets the java.sql.Timestamp. |
boolean |
isLenient()
Gets the lenient flag. |
void |
setChangeable(boolean changeable)
Set the component to be changeable. This is a unified abstraction and will be translated to setEditable or setEnabled, whatever is appropriate to this component. |
void |
setEnabled(boolean enabled)
Sets whether or not this component is enabled. |
void |
setFormValue(Object value)
Sets a value in this component. The method is used to update the view if the data has changed. |
void |
setLenient(boolean lenient)
Sets the "lenient" flag in date format. |
void |
setReferenceDate(Date referenceDate)
Sets the reference date. |
void |
setTimeMode(int timeMode)
Sets the time mode. One of FormCalendar.SHOW_.... |
| Methods inherited from class org.tentackle.ui.FormPanel |
|---|
addActionListener, areValuesChanged, componentAdded, componentRemoved, fireActionPerformed, getFormValues, getTitle, isAllChangeable, isHonourAllChangeable, removeActionListener, saveValues, setAllChangeable, setFormValues, setFormValuesKeepChanged, setHonourAllChangeable, setTitle, triggerValuesChanged |
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int SHOW_AUTO
| Constructor Detail |
|---|
public FormCalendarField()
| Method Detail |
|---|
public void setTimeMode(int timeMode)
FormCalendar.SHOW_....
timeMode - the time mode, -1 if from date format (default)FormCalendarpublic int getTimeMode()
FormCalendar.SHOW_...
public void setLenient(boolean lenient)
lenient - true if lenientpublic boolean isLenient()
public void setEnabled(boolean enabled)
javax.swing.JComponentNote: Disabling a component does not disable its children.
Note: Disabling a lightweight component does not prevent it from receiving MouseEvents.
setEnabled in class JComponentenabled - true if this component should be enabled, false otherwiseComponent.isEnabled(),
Component.isLightweight()public void setChangeable(boolean changeable)
FormComponent
setChangeable in interface FormComponentsetChangeable in class FormComponentPanelchangeable - true the user can edit the data, false if show onlypublic void setFormValue(Object value)
FormComponent
setFormValue in interface FormComponentsetFormValue in class FormComponentPanelvalue - is the object to setpublic Date getFormValue()
FormComponent
getFormValue in interface FormComponentgetFormValue in class FormComponentPanelpublic Date getDate()
java.sql.Date.
public Timestamp getTimestamp()
java.sql.Timestamp.
public Time getTime()
java.sql.Time.
public Date getReferenceDate()
public void setReferenceDate(Date referenceDate)
referenceDate - the reference date, null = today
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||