|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--javax.swing.JComponent | +--javax.swing.JPanel | +--com.ibm.spinner.SpinnerGUI | +--com.ibm.spinner.Spinner | +--com.ibm.spinner.CalendarSpinner | +--com.ibm.spinner.TimeSpinner
A spinner which displays and spins time. The time value can be changed by clicking on different subfields and spinning on them. The user can also type in a time string to set the current value.
Inner classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
Field Summary | |
static java.lang.String |
FULL
One kind of date format string. |
static java.lang.String |
LONG
One kind of date format string. |
static java.lang.String |
MEDIUM
One kind of date format string. |
static java.lang.String |
SHORT
One kind of date format string. |
Fields inherited from class com.ibm.spinner.CalendarSpinner |
DATE,
FULL,
HOUR,
LONG,
MEDIUM,
MINUTE,
MONTH,
SECOND,
SHORT,
YEAR |
Fields inherited from class com.ibm.spinner.SpinnerGUI |
SPIN_HORIZONTAL,
SPIN_VERTICAL |
Fields inherited from class javax.swing.JComponent |
TOOL_TIP_TEXT_KEY,
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 |
Constructor Summary | |
TimeSpinner()
Default constructor which constructs a DateSpinner with the time zone set to that of the host, and the formatString property set to the default locale's Dateformat. |
Method Summary | |
void |
setCalendar(java.util.Calendar newCalendar)
Sets the current calendar's six time fields ,which are year, month, date, hour, minute, second the same with the time fields of another calendar. |
void |
setCaretPos(int newCaretPos)
Sets the current caret positon of the text field. |
void |
setFormatString(java.lang.String newFormatString)
Set the user defined pattern string for formatting and parsing date in a locale-sensitive manner. |
void |
setFormattingStyle(int newFormattingStyle)
Sets the default formatting styles which can be FULL, LONG, MEDIUM, of SHORT. |
void |
setMaximum(java.util.Calendar newMaximumCalendar)
Sets the maximum property of calendar. |
void |
setMinimum(java.util.Calendar newMinimumCalendar)
Sets the minimum property of calendar. |
Methods inherited from class com.ibm.spinner.CalendarSpinner |
actionPerformed,
addDateChangedListener,
dateChanged,
focusLost,
getCalendar,
getCaretPos,
getDate,
getDatePartValue,
getDateString,
getDay,
getFormatString,
getFormattingStyle,
getHour,
getMaximum,
getMinimum,
getMinute,
getMonth,
getSecond,
getSQLDate,
getTimePartValue,
getTimeZone,
getValue,
getYear,
isWrapAssociated,
keyPressed,
keyReleased,
mouseReleased,
removeDateChangedListener,
scrollDown,
scrollUp,
setDate,
setDateByFields,
setDatePartValue,
setDateString,
setDay,
setHour,
setMinute,
setMonth,
setSecond,
setTimePartValue,
setTimeZone,
setValue,
setWrapAssociated,
setYear |
Methods inherited from class com.ibm.spinner.Spinner |
addChangeListener,
addSpinnerErrorEventListener,
isWrap,
removeChangeListener,
removeSpinnerErrorEventListener,
setWrap |
Methods inherited from class com.ibm.spinner.SpinnerGUI |
focusGained,
getColumns,
getDecrButtonArrowColor,
getIncrButtonArrowColor,
getMaximumSize,
getMinimumSize,
getOrientation,
getPreferredSize,
isEditable,
isEnabled,
keyTyped,
mouseClicked,
mouseEntered,
mouseExited,
mousePressed,
setBackground,
setColumns,
setDecrButtonArrowColor,
setEditable,
setEnabled,
setFont,
setForeground,
setIncrButtonArrowColor,
setOpaque,
setOrientation |
Methods inherited from class javax.swing.JPanel |
getAccessibleContext,
getUIClassID,
updateUI |
Methods inherited from class javax.swing.JComponent |
addAncestorListener,
addNotify,
addPropertyChangeListener,
addVetoableChangeListener,
computeVisibleRect,
contains,
createToolTip,
firePropertyChange,
firePropertyChange,
firePropertyChange,
firePropertyChange,
firePropertyChange,
firePropertyChange,
firePropertyChange,
firePropertyChange,
getActionForKeyStroke,
getAlignmentX,
getAlignmentY,
getAutoscrolls,
getBorder,
getBounds,
getClientProperty,
getConditionForKeyStroke,
getDebugGraphicsOptions,
getGraphics,
getHeight,
getInsets,
getInsets,
getLocation,
getNextFocusableComponent,
getRegisteredKeyStrokes,
getRootPane,
getSize,
getToolTipLocation,
getToolTipText,
getToolTipText,
getTopLevelAncestor,
getVisibleRect,
getWidth,
getX,
getY,
grabFocus,
hasFocus,
isDoubleBuffered,
isFocusCycleRoot,
isFocusTraversable,
isLightweightComponent,
isManagingFocus,
isOpaque,
isOptimizedDrawingEnabled,
isPaintingTile,
isRequestFocusEnabled,
isValidateRoot,
paint,
paintImmediately,
paintImmediately,
putClientProperty,
registerKeyboardAction,
registerKeyboardAction,
removeAncestorListener,
removeNotify,
removePropertyChangeListener,
removeVetoableChangeListener,
repaint,
repaint,
requestDefaultFocus,
requestFocus,
resetKeyboardActions,
reshape,
revalidate,
scrollRectToVisible,
setAlignmentX,
setAlignmentY,
setAutoscrolls,
setBorder,
setDebugGraphicsOptions,
setDoubleBuffered,
setMaximumSize,
setMinimumSize,
setNextFocusableComponent,
setPreferredSize,
setRequestFocusEnabled,
setToolTipText,
setVisible,
unregisterKeyboardAction,
update |
Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
countComponents,
deliverEvent,
doLayout,
findComponentAt,
findComponentAt,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents,
getLayout,
insets,
invalidate,
isAncestorOf,
layout,
list,
list,
locate,
minimumSize,
paintComponents,
preferredSize,
print,
printComponents,
remove,
remove,
removeAll,
removeContainerListener,
setLayout,
validate |
Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
contains,
createImage,
createImage,
disable,
dispatchEvent,
enable,
enable,
enableInputMethods,
getBackground,
getBounds,
getColorModel,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getInputContext,
getInputMethodRequests,
getLocale,
getLocation,
getLocationOnScreen,
getName,
getParent,
getPeer,
getSize,
getToolkit,
getTreeLock,
gotFocus,
handleEvent,
hide,
imageUpdate,
inside,
isDisplayable,
isLightweight,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
list,
list,
list,
location,
lostFocus,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
postEvent,
prepareImage,
prepareImage,
printAll,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
resize,
resize,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
show,
show,
size,
toString,
transferFocus |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final java.lang.String FULL
public static final java.lang.String LONG
public static final java.lang.String MEDIUM
public static final java.lang.String SHORT
Constructor Detail |
public TimeSpinner()
Method Detail |
public void setCaretPos(int newCaretPos)
newCaretPos
- the sub-field number of the textpublic void setFormatString(java.lang.String newFormatString)
format
- the new formatting stringCalendarSpinner.getFormatString()
public void setFormattingStyle(int newFormattingStyle)
newFormattingStyle
- the default formatting style.public void setMinimum(java.util.Calendar newMinimumCalendar)
newMinimum
- The minimum as a Calendar.public void setMaximum(java.util.Calendar newMaximumCalendar)
newMaximumCalendar
- The maximum as a Calendar.public void setCalendar(java.util.Calendar newCalendar)
newCalendar
- the calendar whose time fields will be used to
change the current one.
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |