|
||||||||||
| 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
|
+--com.zfqjava.swing.JCalendar
JCalendar provides a calendar component.
Client Property:
| Name | Value | Default Value |
|---|---|---|
| JCalendar.headerStyle |
|
Classic_Arrow |
| JCalendar.centerStyle |
|
MonthView |
| JCalendar.footerStyle |
|
Today |
| Inner Class Summary | |
protected class |
JCalendar.AccessibleJCalendar
This class implements accessibility support for the JCalendar class. |
| Inner classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent |
| 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 | |
JCalendar()
Constructs a JCalendar. |
|
| Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
This method should not invoke by user. |
void |
addActionListener(java.awt.event.ActionListener listener)
Adds an action listener to the JCalendar. |
void |
addChangeListener(javax.swing.event.ChangeListener l)
Adds a ChangeListener to the JCalendar component. |
protected void |
fireActionPerformed(java.awt.event.ActionEvent e)
Notifies all listeners that have registered interest for notification on this event type. |
protected void |
fireStateChanged()
Notifies all listeners that have registered interest for notification on this event type. |
javax.accessibility.AccessibleContext |
getAccessibleContext()
Gets the AccessibleContext associated with this JCalendar. |
java.awt.event.ActionListener[] |
getActionListeners()
Returns an array of all the action listeners registered on this JCalendar. |
java.util.Calendar |
getCalendar()
Returns the calendar object used by this JClock. |
CellProvider |
getCellProvider()
Returns the cell provider for renderer. |
AbstractCellRenderer |
getCellRenderer()
Returns the cell renderer for render day. |
javax.swing.event.ChangeListener[] |
getChangeListeners()
Returns an array of all the ChangeListeners added
to this JCalendar with addChangeListener(). |
int |
getDate()
Returns the calendar's current date. |
java.util.Calendar |
getModel()
Deprecated. replaced by getCalendar() |
int |
getMonth()
Returns the calendar's current month. |
java.util.Date |
getTime()
Gets this Calendar's current time. |
CalendarUI |
getUI()
Returns the look and feel (L&F) object that renders this component. |
java.lang.String |
getUIClassID()
Returns a string that specifies the name of the L&F class that renders this component. |
int |
getYear()
Returns this calendar's current year. |
protected java.lang.String |
paramString()
Returns a string representation of this JCalendar. |
void |
removeActionListener(java.awt.event.ActionListener listener)
Removes the specified action listener from the JCalendar. |
void |
removeChangeListener(javax.swing.event.ChangeListener l)
Removes a ChangeListener from the JCalendar component. |
void |
setCalendar(java.util.Calendar cal)
Sets the calendar object used by this JClock. |
void |
setCellProvider(CellProvider cellProvider)
Sets the cell provider for renderer. |
void |
setCellRenderer(AbstractCellRenderer cellRenderer)
Sets the cell renderer for render day. |
void |
setDate(int date)
Sets the day of the month of this JCalendar object to the specified value. |
void |
setModel(java.util.Calendar cal)
Deprecated. replaced by setCalendar(java.util.Calendar) |
void |
setMonth(int month)
Sets the month of this date to the specified value. |
void |
setTime(java.util.Date time)
Sets this Calendar's current time with the given Date. |
void |
setUI(CalendarUI ui)
Sets the look and feel (L&F) object that renders this component. |
void |
setYear(int year)
Sets the year of this JCalendar object to be the specified value. |
void |
updateUI()
Resets the UI property with a value from the current look and feel. |
| 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, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getVerifyInputWhenFocusTarget, getVisibleRect, getWidth, getX, getY, grabFocus, hasFocus, hide, isDoubleBuffered, isFocusCycleRoot, isFocusTraversable, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processFocusEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
| Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getLayout, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setLayout, validate, validateTree |
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, imageUpdate, inside, isDisplayable, isEnabled, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, 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 |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public JCalendar()
JCalendar.| Method Detail |
public void updateUI()
updateUI in class javax.swing.JComponentJComponent.updateUI()public CalendarUI getUI()
public void setUI(CalendarUI ui)
ui - the CalendarUI L&F objectUIDefaults.getUI(javax.swing.JComponent)public java.lang.String getUIClassID()
getUIClassID in class javax.swing.JComponentJComponent.getUIClassID(),
UIDefaults.getUI(javax.swing.JComponent)public java.util.Calendar getModel()
getCalendar()
java.util.Calendar.setModel(java.util.Calendar)public void setModel(java.util.Calendar cal)
setCalendar(java.util.Calendar)
java.util.Calendar.cal - the calendar modelgetModel()public void setCalendar(java.util.Calendar cal)
JClock.cal - the calendar object used by this JClockgetCalendar()public java.util.Calendar getCalendar()
JClock.JClocksetCalendar(java.util.Calendar)public void setTime(java.util.Date time)
date - the given Date.getTime()public java.util.Date getTime()
setTime(java.util.Date)public int getYear()
Calendarpublic void setYear(int year)
year - the year value.Calendarpublic int getMonth()
replaced by Calendar.get(Calendar.MONTH).public void setMonth(int month)
month - the month value between 0-11.replaced by Calendar.set(Calendar.MONTH, int month).public int getDate()
Calendarpublic void setDate(int date)
date - the day of the month value between 1-31.Calendarpublic void setCellRenderer(AbstractCellRenderer cellRenderer)
cellRenderer - the cell renderergetCellRenderer()public AbstractCellRenderer getCellRenderer()
setCellRenderer(com.zfqjava.swing.cell.AbstractCellRenderer)public void setCellProvider(CellProvider cellProvider)
cellProvider - the cell providergetCellProvider()public CellProvider getCellProvider()
setCellProviderpublic void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListenerpublic void addActionListener(java.awt.event.ActionListener listener)
JCalendar.listener - the listener to addJCalendar()public void removeActionListener(java.awt.event.ActionListener listener)
JCalendar.listener - the listener to removepublic java.awt.event.ActionListener[] getActionListeners()
ActionListeners or an empty
array if no action listeners are currently registeredaddActionListener(java.awt.event.ActionListener),
removeActionListener(java.awt.event.ActionListener)protected void fireActionPerformed(java.awt.event.ActionEvent e)
e - the action event to fireEventListenerListpublic void addChangeListener(javax.swing.event.ChangeListener l)
JCalendar component.
Note: Fires ChangeEvent when month or year or date selection has
changed. If only interesting date changed event, attach a
PropertyChangeListener and listen date property,
about month or year you can use the same style.
l - the listener to addpublic void removeChangeListener(javax.swing.event.ChangeListener l)
JCalendar component.
Note: Fires ChangeEvent when month or year or date selection has
changed. If only interesting date changed event, attach a
PropertyChangeListener and listen date property,
about month or year you can use the same style.
l - the listener to removepublic javax.swing.event.ChangeListener[] getChangeListeners()
ChangeListeners added
to this JCalendar with addChangeListener().
Note: Fires ChangeEvent when month or year or date selection has
changed. If only interesting date changed event, attach a
PropertyChangeListener and listen date property,
about month or year you can use the same style.
ChangeListeners added or an empty
array if no listeners have been addedprotected void fireStateChanged()
EventListenerListprotected java.lang.String paramString()
null.paramString in class javax.swing.JComponentpublic javax.accessibility.AccessibleContext getAccessibleContext()
getAccessibleContext in interface javax.accessibility.AccessiblegetAccessibleContext in class javax.swing.JComponent
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||