public class DefaultFieldEditor<T> extends ToolDialog implements FieldEditor<T>
FieldEditor interface.FieldEditor,
Serialized Formjavax.swing.JDialog.AccessibleJDialogjava.awt.Dialog.AccessibleAWTDialog, java.awt.Dialog.ModalExclusionType, java.awt.Dialog.ModalityTypejava.awt.Window.AccessibleAWTWindow, java.awt.Window.TypeaccessibleContext, rootPane, rootPaneCheckingEnabledBOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTCENTER, EAST, NORTH, SOUTH, WEST| Constructor and Description |
|---|
DefaultFieldEditor(java.awt.Window hook,
javax.swing.JButton callerButton) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clears the content
|
protected javax.swing.JPanel |
createMainPanel() |
protected void |
doOnApply()
Should be overridden in order to provide an apply action
|
protected javax.swing.JButton |
getCallerButton() |
T |
getValue()
Returns the current value or null if no content exists.
|
protected boolean |
hasApplyButton()
Defines whether an Apply button should be displayed (default false).
|
protected boolean |
hasCancelButton()
Defines whether a Cancel button should be displayed (default false).
|
boolean |
isEmpty()
Tells whether the editor has any content.
|
boolean |
isInputValid()
Performs a check whether the editor's input is valid.
|
boolean |
isLocked()
Tells whether the editor is currently locked.
|
boolean |
isNotNull()
Tells whether the editor requires input.
|
void |
popup(javax.swing.JComponent hook,
T value)
Pops up the editor to become visible (it is usually a dialog or a frame).
|
void |
setInsertDefaultValue()
Requests the editor to lookup for an insert default value and loads it.
|
void |
setLocked(boolean isLocked)
Locks the editor and makes editing impossible.
|
void |
setNotNull(boolean isNotNull)
Sets the editor's input to mandatory.
|
void |
setValue(T value)
Loads the data content which refers to a particular object.
|
addApplyListener, apply, cancel, close, closeByIcon, createButtonPanel, createWindowAdapter, doOnApplyError, doOnCancel, doOnClose, doOnPopup, getApplicationContext, getApplier, getApplyAndCloseButton, getApplyButton, getButtonPanel, getCaller, getCancelButton, getClearButton, getCloseButton, getLogChannel, getPreferredWindowAlignment, getWindowAdapter, hasApplyAndCloseButton, hasButtonPanel, hasClearButton, hasCloseButton, isClosedOnApply, isLogDebug, isLogVerbose, locate, logDebug, logDump, logError, logError, logFatal, logInfo, logVerbose, logWarning, pack, popup, removeApplyListener, setDefaultButton, setLogChannel, setRelocateOnPopup, wasCancelleddispose, getMinimumHeight, getMinimumWidth, isDisposeOnClose, isErrorAttachable, isLocated, isPacked, registerSubDialog, repack, setLocation, setLocationRelativeTo, setLocationRelativeTo, setLocationToCenter, setTitle, setVisible, shiftLocation, toDumpString, toDumpString, toString, toStringaddImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, updateaddNotify, getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setBackground, setModal, setModalityType, setOpacity, setResizable, setShape, setTitle, setUndecorated, show, toBackaddPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocation, setLocationByPlatform, setMinimumSize, setModalExclusionType, setSize, setSize, setType, toFrontadd, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTreeaction, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, transferFocus, transferFocusBackward, transferFocusUpCycleclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetLocation, getMinimumHeight, getMinimumWidth, getSize, getTitle, getToolkit, isPacked, pack, popup, setLocation, setLocationRelativeTo, setMinimumSize, setPreferredSize, shiftLocationtoDumpString, toDumpString, toString, toStringgetRootPanepublic DefaultFieldEditor(java.awt.Window hook,
javax.swing.JButton callerButton)
protected javax.swing.JButton getCallerButton()
protected final javax.swing.JPanel createMainPanel()
protected boolean hasCancelButton()
ToolDialoghasCancelButton in class ToolDialogprotected boolean hasApplyButton()
ToolDialoghasApplyButton in class ToolDialogpublic void clear()
Clearableclear in interface FieldEditor<T>clear in interface Clearableclear in class ToolDialogpublic void setValue(T value)
FieldEditorsetValue in interface FieldEditor<T>public boolean isInputValid()
FieldEditorisInputValid in interface FieldEditor<T>public boolean isLocked()
FieldEditorisLocked in interface FieldEditor<T>public boolean isNotNull()
FieldEditorisNotNull in interface FieldEditor<T>public boolean isEmpty()
FieldEditorisEmpty in interface FieldEditor<T>public void setLocked(boolean isLocked)
FieldEditorsetLocked in interface FieldEditor<T>public void setNotNull(boolean isNotNull)
FieldEditorsetNotNull in interface FieldEditor<T>public void setInsertDefaultValue()
FieldEditorsetInsertDefaultValue in interface FieldEditor<T>public void popup(javax.swing.JComponent hook,
T value)
FieldEditorpopup in interface FieldEditor<T>protected void doOnApply()
throws java.lang.Exception
ToolDialogdoOnApply in class ToolDialogjava.lang.Exceptionpublic T getValue()
FieldEditorgetValue in interface FieldEditor<T>Copyright © 2014 EsprIT-Systems. All Rights Reserved.