Package org.gvsig.app.gui
Class WizardPanel
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.gvsig.app.gui.WizardPanel
- All Implemented Interfaces:
ImageObserver,MenuContainer,Serializable,Accessible
- Direct Known Subclasses:
FilesystemExplorerWizardPanel
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanelNested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponentNested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainerNested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy -
Field Summary
FieldsFields inherited from class javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWFields inherited from class java.awt.Component
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTFields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanaddArguments(org.gvsig.tools.arguments.Arguments args) protected voidvoidaddWizardListener(WizardListener listener) booleanThis method is called for example when user changes tab in add layer dialog (new tab's settings are valid?)voidvoidcallStateChanged(boolean finishable) protected voidabstract voidclose()protected voiddoAddLayer(String layerName, org.gvsig.fmap.dal.DataStoreParameters parameters) protected voiddoAddLayer(org.gvsig.fmap.mapcontrol.MapControl mapControl, String layerName, org.gvsig.fmap.dal.DataStoreParameters parameters) abstract voidexecute()Executes the wizard and returns anything created in the process.protected voidfixCRS(org.gvsig.fmap.dal.DataStoreParameters params) org.gvsig.fmap.mapcontext.MapContextYou can use it to extract information from the MapContext that will receive the new layer.org.gvsig.fmap.mapcontrol.MapControlYou can use it to interact with the MapControl component that will receive the new layer, in order to get user feedback (for instance a bounding box).abstract org.gvsig.fmap.dal.DataStoreParameters[]abstract voidbooleanChecks whether the MapControl is available.voidremoveWizardListener(WizardListener listener) voidsetMapContext(org.gvsig.fmap.mapcontext.MapContext mapContext) Sets the MapContext that will receive the new layervoidsetMapCtrl(org.gvsig.fmap.mapcontrol.MapControl mapCtrl) Sets the MapControl that will receive the new layerprotected voidsetTabName(String name) protected voidvoidwaitTasks(long timeoutms) Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIMethods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateMethods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTreeMethods 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, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, 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, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Field Details
-
arguments
protected org.gvsig.tools.arguments.Arguments arguments
-
-
Constructor Details
-
WizardPanel
public WizardPanel()
-
-
Method Details
-
addWizardListener
-
callError
-
removeWizardListener
-
callStateChanged
public void callStateChanged(boolean finishable) -
setTabName
-
getTabName
-
initWizard
public abstract void initWizard() -
execute
public abstract void execute() -
executeWizard
Executes the wizard and returns anything created in the process.- Returns:
- anything created in the process
-
close
public abstract void close() -
getParameters
public abstract org.gvsig.fmap.dal.DataStoreParameters[] getParameters() -
getMapCtrl
public org.gvsig.fmap.mapcontrol.MapControl getMapCtrl()You can use it to interact with the MapControl component that will receive the new layer, in order to get user feedback (for instance a bounding box). Check theisMapControlAvailable()method before accessing the MapControl because it may not be available (for instance when adding layers to a MapContext not associated with a View). For the moment, this method will return a non-null MapControl for compatibility reasons, but you should still checkisMapControlAvailable()to be sure it is a valid one, as it could only be a fake MapControl. It is recommended to usegetMapContext()method when no interaction is needed with the map user interface (for instance to get the active projection, visible extent, etc)- Returns:
- Returns the mapCtrl.
-
setMapCtrl
public void setMapCtrl(org.gvsig.fmap.mapcontrol.MapControl mapCtrl) Sets the MapControl that will receive the new layer- Parameters:
mapCtrl- The mapCtrl to set.
-
getMapContext
public org.gvsig.fmap.mapcontext.MapContext getMapContext()You can use it to extract information from the MapContext that will receive the new layer. For example, projection to use, or visible extent.- Returns:
- Returns the MapContext.
-
setMapContext
public void setMapContext(org.gvsig.fmap.mapcontext.MapContext mapContext) Sets the MapContext that will receive the new layer- Parameters:
mapContext- The mapContext to set.
-
isMapControlAvailable
public boolean isMapControlAvailable()Checks whether the MapControl is available. The MapControl may not be available in some circumstances, for instance when adding layers to a MapContext not associated with a View. A MapContext should always be available on thegetMapContext()method.- Returns:
- true if the MapControl is available, false otherwise
-
doAddLayer
-
doAddLayer
protected void doAddLayer(org.gvsig.fmap.mapcontrol.MapControl mapControl, String layerName, org.gvsig.fmap.dal.DataStoreParameters parameters) - Parameters:
mapControl-layerName-parameters-
-
areSettingsValid
public boolean areSettingsValid()This method is called for example when user changes tab in add layer dialog (new tab's settings are valid?)- Returns:
- whether current wizard settings are enough (for example, to enable an Accept button in a container)
-
fixCRS
protected void fixCRS(org.gvsig.fmap.dal.DataStoreParameters params) -
addArguments
public boolean addArguments(org.gvsig.tools.arguments.Arguments args) -
addTask
-
startTask
-
clearTasks
protected void clearTasks() -
waitTasks
public void waitTasks(long timeoutms)
-