|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel com.isti.util.gui.IstiTimePanel
Class IstiTimePanel implements the time panel.
Nested Class Summary |
Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
protected java.lang.String |
calendarTipText
|
protected java.lang.String |
dayOfMonthTextTip
|
protected static boolean |
debugFlag
|
protected java.lang.String |
monthTipText
|
protected java.lang.String |
timeTipText
|
protected java.lang.String |
yearTextTip
|
Fields inherited from class javax.swing.JComponent |
accessibleContext, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Container |
|
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 | |
IstiTimePanel()
Creates a time panel with the default title for the panel and the calendar popup. |
|
IstiTimePanel(java.lang.String title)
Creates a time panel with the given title for the panel and the calendar popup. |
|
IstiTimePanel(java.lang.String title,
boolean showZeroTextFlag)
Creates a time panel with the given title for the panel and the calendar popup using the provided calendar. |
|
IstiTimePanel(java.lang.String title,
boolean showZeroTextFlag,
java.util.Calendar calObj)
Creates a time panel with the given title for the panel and the calendar popup using the provided calendar. |
Method Summary | |
void |
addUpdateListener(UpdateListener l)
Adds an UpdateListener . |
(package private) void |
calendarButton_actionPerformed(java.awt.event.ActionEvent e)
Calendar button processing |
protected void |
fireUpdate(java.awt.Component component,
java.lang.Object e)
Notification of an update event. |
java.util.Calendar |
getCalendar()
Gets the calendar for this panel. |
int |
getDayOfMonth()
Gets the current day of the month. |
java.util.Date |
getMaxTime()
Gets the maximum time. |
java.util.Date |
getMinTime()
Gets the minimum time. |
int |
getMonth()
Gets the current month. |
java.util.Date |
getTime()
Get the date that is specified in this object. |
java.util.TimeZone |
getTimeZone()
Gets the time zone. |
java.lang.String |
getTitle()
Gets the title of the time panel. |
int |
getYear()
Gets the current year. |
boolean |
isEnabled()
Determines whether this component is enabled. |
boolean |
isShowLabels()
Determines if the labels are shown. |
protected boolean |
isTimeUpdate()
Gets the time update flag. |
void |
processUpdate(java.awt.Component component,
java.lang.Object e)
Process an update. |
void |
removeUpdateListener(UpdateListener l)
Removes an UpdateListener . |
void |
setEnabled(boolean b)
Enables or disables this component, depending on the value of the parameter b . |
boolean |
setMaxTime(java.util.Date date)
Sets the maximum time. |
boolean |
setMinTime(java.util.Date date)
Sets the minimum time. |
void |
setShowLabels(boolean b)
Enables or disables showing the labels. |
boolean |
setTime(java.util.Date date)
Sets the time. |
protected void |
setTimeUpdateFlag(boolean b)
Sets the time update flag. |
void |
setTimeZone(java.util.TimeZone value)
Sets the time zone with the given time zone value. |
void |
setTitle(java.lang.String title)
Sets the title of the time panel. |
java.lang.String |
toString()
Returns a string representation of this component and its values. |
protected void |
updateDateFields()
Update the date fields to the current date. |
protected void |
updateDays()
Updates the days of the month. |
Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, 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, processInputMethodEvent, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static boolean debugFlag
protected final java.lang.String monthTipText
protected final java.lang.String dayOfMonthTextTip
protected final java.lang.String yearTextTip
protected final java.lang.String timeTipText
protected final java.lang.String calendarTipText
Constructor Detail |
public IstiTimePanel()
public IstiTimePanel(java.lang.String title)
title
- the title for the panel and the calendar popup
or null for default.public IstiTimePanel(java.lang.String title, boolean showZeroTextFlag)
title
- the title for the panel and the calendar popup
or null for default.showZeroTextFlag
- the show zero test flag,
if true spaces in the text are replaced with zeros.public IstiTimePanel(java.lang.String title, boolean showZeroTextFlag, java.util.Calendar calObj)
title
- the title for the panel and the calendar popup
or null for default.showZeroTextFlag
- the show zero test flag,
if true spaces in the text are replaced with zeros.calObj
- calendar object or null to create a new one.Method Detail |
public java.util.Date getMaxTime()
public java.util.Date getMinTime()
public java.util.Date getTime()
public java.util.TimeZone getTimeZone()
public java.lang.String getTitle()
public boolean isEnabled()
setEnabled
method.
true
if the component is enabled;
false
otherwise.setEnabled(boolean)
public boolean isShowLabels()
public void setEnabled(boolean b)
b
. An enabled component can respond to user
input and generate events. Components are enabled initially by default.
b
- If true
, this component is
enabled; otherwise this component is disabled.isEnabled()
public void setShowLabels(boolean b)
b
- If true the labels are shown; otherwise the labels are not shown.public boolean setMaxTime(java.util.Date date)
date
- the date to set or null to clear.
public boolean setMinTime(java.util.Date date)
date
- the date to set or null to clear.
public boolean setTime(java.util.Date date)
date
- the date to set or null to clear.
public void setTimeZone(java.util.TimeZone value)
value
- the given time zone.public void setTitle(java.lang.String title)
title
- the title for the time panel.public java.lang.String toString()
protected boolean isTimeUpdate()
protected void setTimeUpdateFlag(boolean b)
b
- true if time is being updated, false otherwise.protected void updateDateFields()
protected void updateDays()
void calendarButton_actionPerformed(java.awt.event.ActionEvent e)
e
- action eventpublic int getMonth()
public int getDayOfMonth()
public int getYear()
public java.util.Calendar getCalendar()
public void addUpdateListener(UpdateListener l)
UpdateListener
. The listener will
receive an update event
the user finishes making a selection.
l
- the UpdateListener
that is to be notifiedpublic void removeUpdateListener(UpdateListener l)
UpdateListener
.
l
- the UpdateListener
to removeprotected void fireUpdate(java.awt.Component component, java.lang.Object e)
component
- the component.e
- the event or null if none.public void processUpdate(java.awt.Component component, java.lang.Object e)
processUpdate
in interface UpdateListener
component
- the component.e
- the event or null if none.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |