|
EchoPoint 1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object nextapp.echo.Component nextapp.echo.Container echopoint.EchoPointComponent echopoint.WizardPane
The WizardPane
class provides a component to the Echo Web Framework that
allows the user to navigate through a series of logical steps.
Any Component object can be used as the interior of a given pane, however in general you would use a Panel object as the contents, and then fill that Panel with other components.
The WizardPane
uses a SingleSelectionModel
to represent the set of tab
indices and the currently selected index.
If the count is greater than 0, then there will always be a selected index, which by default will be initialized to the first component. If the count is 0, then the selected index will be -1.
WizardPane
has an optimisation in place that means that only the
currently selected component is given a rendering peer. This ensures that the
smallest amount of memory is sxued to render the contents.
The WizardPane
will call any WizardNavigationListener's
that are registered when the user wants to navigate to another component.
If any listeners are provided, then they can throw a WizardNavigationVetoException
to stop the user from navigating way from the current pane. You might do this to implement
validation of the pane.
The WizardPane stores the selected index before invoking the WizardNavigationListener interface. If, after completion of the call, the model's selected index is different to the saved index, the selected index will not be decremented or incremented. This allows you to "jump" the WizardPane to a specific index via the WizardNavigationListener processing.
The WizardPane can contain a TitleBar
object as its title and footer.
Every time the pane changes, the text of the title and footer will change.
The width and height of the WizardPane
can be set. This sets the dimensions
of the interior of the contents area. If the width is not set, ie it is set to Integer.MAX_VALUE or
Integer.MIN_VALUE, then the WizardPane
will fill its containing component.
Scrollbars can also be used within the WizardPane
.
for more information.
,
Serialized FormNested Class Summary | |
static class |
WizardPane.NestedStyleInfo
Nested public static StyleInfo class. |
Field Summary | |
static java.lang.String |
BORDER_COLOR_CHANGED_PROPERTY
|
static java.lang.String |
BORDER_SIZE_CHANGED_PROPERTY
|
static java.lang.String |
BUTTONS_CHANGED_PROPERTY
|
static java.lang.String |
COMPONENT_CHANGED_PROPERTY
|
static nextapp.echo.Insets |
DEFAULT_INSETS
|
static java.lang.String |
ENTRY_CHANGED_PROPERTY
|
static java.lang.String |
FINISH_LAST_ONLY_CHANGED_PROPERTY
|
static java.lang.String |
FOOTER_CHANGED_PROPERTY
|
static java.lang.String |
FOOTERBAR_CHANGED_PROPERTY
|
static java.lang.String |
HEIGHT_CHANGED_PROPERTY
|
static java.lang.String |
INSETS_CHANGED_PROPERTY
|
static java.lang.String |
MODEL_CHANGED_PROPERTY
|
static java.lang.String |
PLACEMENT_CHANGED_PROPERTY
|
static java.lang.String |
RENDERING_CHANGED_PROPERTY
|
static java.lang.String |
SCROLL_BAR_X_CHANGED_PROPERTY
This property name is fired when the scolling bar X value changes |
static java.lang.String |
SCROLL_BAR_Y_CHANGED_PROPERTY
This property name is fired when the scolling bar Y value changes |
static java.lang.String |
SCROLLBAR_POLICY_CHANGED_PROPERTY
|
static java.lang.String |
SELECTED_INDEX_CHANGED_PROPERTY
|
static java.lang.String |
STYLE_BORDER_COLOR
A style constant for the Border Color property. |
static java.lang.String |
STYLE_BORDER_SIZE
A style constant for the Border Size property. |
static java.lang.String |
STYLE_FINISH_ONLY_ON_LAST
A style constant for the FinishOnlyOnLast property. |
static java.lang.String |
STYLE_INSETS
A style constant for the Insets property. |
static java.lang.String |
TITLE_CHANGED_PROPERTY
|
static java.lang.String |
TITLEBAR_CHANGED_PROPERTY
|
static java.lang.String |
WIDTH_CHANGED_PROPERTY
|
Fields inherited from class echopoint.EchoPointComponent |
STYLE_TOOL_TIP_TEXT, TOOL_TIP_TEXT_CHANGED_PROPERTY, toolTipPopUp |
Fields inherited from class nextapp.echo.Component |
BACKGROUND_CHANGED_PROPERTY, CHILDREN_CHANGED_PROPERTY, ENABLED_CHANGED_PROPERTY, FONT_CHANGED_PROPERTY, FOREGROUND_CHANGED_PROPERTY, IDENTIFIER_CHANGED_PROPERTY, listenerList, LOCALE_CHANGED_PROPERTY, STYLE_BACKGROUND, STYLE_FONT, STYLE_FOREGROUND, UPDATE_PROPERTY, VISIBLE_CHANGED_PROPERTY |
Fields inherited from interface echopoint.positionable.Scrollable |
SCROLLBARS_ALWAYS, SCROLLBARS_AUTO, SCROLLBARS_CLIPHIDE, SCROLLBARS_NEVER, STYLE_HEIGHT, STYLE_SCROLL_BAR_POLICY, STYLE_WIDTH, UNDEFINED, undefinedSymbolic |
Fields inherited from interface echopoint.positionable.MouseCursorable |
borderStyleSymbolics, CURSOR_AUTO, CURSOR_CROSSHAIR, CURSOR_CUSTOM_URI, CURSOR_DEFAULT, CURSOR_E_RESIZE, CURSOR_HELP, CURSOR_MOVE, CURSOR_N_RESIZE, CURSOR_NE_RESIZE, CURSOR_NW_RESIZE, CURSOR_POINTER, CURSOR_S_RESIZE, CURSOR_SE_RESIZE, CURSOR_SW_RESIZE, CURSOR_TEXT, CURSOR_W_RESIZE, CURSOR_WAIT, STYLE_MOUSE_CURSOR, STYLE_MOUSE_CURSOR_URI |
Constructor Summary | |
WizardPane()
Constructs a WizardPane with the button placement as EchoConstants.BOTTOM |
|
WizardPane(int buttonPlacement)
Constructs a new WizardPane |
Method Summary | |
void |
actionPerformed(nextapp.echo.event.ActionEvent actionEvent)
Called when one of the buttons has been pressed and navigation should be done. |
void |
add(nextapp.echo.Component component)
Adds a component to the WizardPane
Cover method for insert() |
void |
add(nextapp.echo.Component component,
int index)
Adds a component to the WizardPane at the specified index
Cover method for insert()
|
void |
add(java.lang.String title,
nextapp.echo.Component component)
Adds a component to the WizardPane |
void |
add(java.lang.String title,
java.lang.String footer,
nextapp.echo.Component component)
Adds a component to the WizardPane |
void |
addChangeListener(nextapp.echo.event.ChangeListener l)
Adds a ChangeListener to the WizardPane. |
void |
addWizardNavigationListener(WizardNavigationListener l)
Adds a WizardNavigationListener to the WizardPane. |
void |
applyStyle(nextapp.echo.Style style)
Applies the provided style to the component. |
nextapp.echo.Color |
getBorderColor()
|
int |
getBorderSize()
|
nextapp.echo.Button |
getCancelButton()
Returns the button that acts as the "Cancel" button in the WizardPane . |
nextapp.echo.Component |
getComponentAt(int index)
|
int |
getCount()
Returns the number of entries within the WizardPane . |
nextapp.echo.Button |
getFinishButton()
Returns the button that acts as the "Finish" button in the WizardPane . |
TitleBar |
getFooter()
|
java.lang.String |
getFooterAt(int index)
|
int |
getHeight()
Returns the height of the WizardPane . |
nextapp.echo.Insets |
getInsets()
Returns the insets (margins) of the tabbed pane contents. |
SingleSelectionModel |
getModel()
Returns the model associated with this WizardPane . |
nextapp.echo.Button |
getNextButton()
Returns the button that acts as the "Next" button in the WizardPane . |
int |
getPlacement()
|
nextapp.echo.Button |
getPreviousButton()
Returns the button that acts as the "Previous" button in the WizardPane . |
int |
getScrollBarPolicy()
Returns the ScrollBarPolicy in place This can be one of : SCOLLBARS_NONE SCOLLBARS_ALWAYS SCOLLBARS_AUTO |
int |
getScrollBarX()
Returns the position of the horizontal scroll bar, in pixels offset from the left of the component. |
int |
getScrollBarY()
Returns the position of the vertical scroll bar, in pixels offset from the top the component. |
nextapp.echo.Component |
getSelectedComponent()
|
int |
getSelectedIndex()
Returns the currently selected index or -1 if none is selected |
TitleBar |
getTitle()
|
java.lang.String |
getTitleAt(int index)
|
int |
getWidth()
Returns the width of the WizardPane . |
int |
indexOfComponent(nextapp.echo.Component c)
Returns the index of the given Component or -1 if it is not found |
int |
indexOfTitle(java.lang.String title)
Returns the index with the given title or -1 if it is not found |
void |
insert(java.lang.String title,
nextapp.echo.Component component,
int index)
Insert a Component at the specified index. |
void |
insert(java.lang.String title,
java.lang.String footer,
nextapp.echo.Component component,
int index)
Insert a Component at the specified index. |
boolean |
isFinishButtonOnLastOnly()
This returns TRUE if the Finish button will be shown on the last wizard page only. |
void |
remove(nextapp.echo.Component c)
Removes a entry from the WizardPane at represented by the Component c |
void |
remove(int index)
Removes a Component entry from the WizardPane at the specified index. |
void |
removeAll()
Removes all entries from the WizardPane . |
void |
removeChangeListener(nextapp.echo.event.ChangeListener l)
Removes a ChangeListener from this component. |
void |
removeComponentAt(int index)
Removes a Component entry from the WizardPane at the specified index. |
void |
removeWizardNavigationListener(WizardNavigationListener l)
Removes a WizardNavigationListener to the WizardPane. |
protected void |
reRegisterComponents(nextapp.echo.Component oldValue,
nextapp.echo.Component newValue)
Adds and removes a Component as a child of the WizardPane. |
java.lang.Object |
set(java.lang.reflect.Field field,
java.lang.Object newValue)
Called to save the old value of a field, set in a new value and return the old value of a field. |
void |
setBorderColor(nextapp.echo.Color newValue)
Sets the border color of the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BORDER_COLOR_CHANGED_PROPERTY |
void |
setBorderSize(int newBorderSize)
Sets the border size of the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BORDER_SIZE_CHANGED_PROPERTY |
void |
setCancelButton(nextapp.echo.Button newButton)
Sets the button that acts as the "Cancel" button in the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BUTTONS_CHANGED_PROPERTY |
void |
setComponentAt(int index,
nextapp.echo.Component component)
Sets the Component at the specified index
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.COMPONENT_CHANGED_PROPERTY |
void |
setEnabled(boolean newValue)
|
void |
setFinishButton(nextapp.echo.Button newButton)
Sets the button that acts as the "Finish" button in the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BUTTONS_CHANGED_PROPERTY |
void |
setFinishButtonOnLastOnly(boolean newFinishButtonOnLastOnly)
if this is set to TRUE, the Finish button will be shown on the last wizard page only. |
void |
setFooter(TitleBar newFooterBar)
Sets the footer TitleBar of the WizardPane. |
void |
setFooterAt(int index,
java.lang.String footerText)
Sets the footer at the specified index This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.FOOTER_CHANGED_PROPERTY |
void |
setHeight(int newValue)
Sets the height of the WizardPane . |
void |
setInsets(nextapp.echo.Insets newValue)
Sets the insets (margins) of the WizardPane |
void |
setModel(SingleSelectionModel model)
Sets the model to be used with this WizardPane
. |
void |
setNextButton(nextapp.echo.Button newButton)
Sets the button that acts as the "Next" button in the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BUTTONS_CHANGED_PROPERTY |
void |
setPlacement(int newPlacement)
Sets the placement of buttons within the WizardPane
|
void |
setPreviousButton(nextapp.echo.Button newButton)
Sets the button that acts as the "Previous" button in the WizardPane
This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.BUTTONS_CHANGED_PROPERTY |
void |
setScrollBarPolicy(int newScrollBarPolicy)
This sets the scroll bar policy to use. |
void |
setScrollBarX(int newValue)
Sets the position of the horizontal scroll bar, in pixels offset from the left of the component. |
void |
setScrollBarY(int newValue)
Sets the position of the vertical scroll bar, in pixels offset from the top of the component. |
void |
setSelectedIndex(int index)
Sets the selected tab of the WizardPane . |
void |
setTitle(TitleBar newTitleBar)
Sets the title TitleBar of the WizardPane. |
void |
setTitleAt(int index,
java.lang.String title)
Sets the title at the specified index This methods fires a PropertyChangeEvent with a
getPropertyName() value of
WizardPane.TITLE_CHANGED_PROPERTY |
void |
setWidth(int newValue)
Sets the width of the WizardPane . |
void |
validate()
|
Methods inherited from class echopoint.EchoPointComponent |
getMouseCursor, getMouseCursorURI, getToolTipPopUp, getToolTipText, set, set, set, set, set, set, set, set, set, setEnabledAllChildren, setMouseCursor, setMouseCursorURI, setToolTipText |
Methods inherited from class nextapp.echo.Component |
addHierarchyListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getComponent, getComponentCount, getComponents, getEchoInstance, getFont, getForeground, getIdentifier, getLocale, getParent, indexOf, init, isAncestorOf, isEnabled, isRegistered, isShowing, isVisible, removeHierarchyListener, removePropertyChangeListener, setBackground, setFont, setForeground, setIdentifier, setLocale, setVisible, update |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String BORDER_COLOR_CHANGED_PROPERTY
public static final java.lang.String BORDER_SIZE_CHANGED_PROPERTY
public static final java.lang.String BUTTONS_CHANGED_PROPERTY
public static final java.lang.String COMPONENT_CHANGED_PROPERTY
public static final nextapp.echo.Insets DEFAULT_INSETS
public static final java.lang.String ENTRY_CHANGED_PROPERTY
public static final java.lang.String FINISH_LAST_ONLY_CHANGED_PROPERTY
public static final java.lang.String FOOTER_CHANGED_PROPERTY
public static final java.lang.String FOOTERBAR_CHANGED_PROPERTY
public static final java.lang.String HEIGHT_CHANGED_PROPERTY
public static final java.lang.String INSETS_CHANGED_PROPERTY
public static final java.lang.String MODEL_CHANGED_PROPERTY
public static final java.lang.String PLACEMENT_CHANGED_PROPERTY
public static final java.lang.String RENDERING_CHANGED_PROPERTY
public static final java.lang.String SCROLL_BAR_X_CHANGED_PROPERTY
public static final java.lang.String SCROLL_BAR_Y_CHANGED_PROPERTY
public static final java.lang.String SCROLLBAR_POLICY_CHANGED_PROPERTY
public static final java.lang.String SELECTED_INDEX_CHANGED_PROPERTY
public static final java.lang.String STYLE_BORDER_COLOR
nextapp.echo.Color.
public static final java.lang.String STYLE_BORDER_SIZE
Integer.
public static final java.lang.String STYLE_FINISH_ONLY_ON_LAST
boolean
public static final java.lang.String STYLE_INSETS
nextapp.echo.Insets.
public static final java.lang.String TITLE_CHANGED_PROPERTY
public static final java.lang.String TITLEBAR_CHANGED_PROPERTY
public static final java.lang.String WIDTH_CHANGED_PROPERTY
Constructor Detail |
public WizardPane()
EchoConstants.BOTTOM
public WizardPane(int buttonPlacement)
buttonPlacement
- the button placement of the WizardPane,
can be one of the following values.
Method Detail |
public void actionPerformed(nextapp.echo.event.ActionEvent actionEvent)
actionPerformed
in interface nextapp.echo.event.ActionListener
public void add(nextapp.echo.Component component)
WizardPane
Cover method for insert()
component
- public void add(nextapp.echo.Component component, int index)
WizardPane
at the specified index
Cover method for insert()
component
- public void add(java.lang.String title, nextapp.echo.Component component)
WizardPane
public void add(java.lang.String title, java.lang.String footer, nextapp.echo.Component component)
WizardPane
public void addChangeListener(nextapp.echo.event.ChangeListener l)
ChangeListener
to the WizardPane.
l
- The ChangeListener
to be added.public void addWizardNavigationListener(WizardNavigationListener l)
WizardNavigationListener
to the WizardPane.
l
- The ChangeListener
to be added.public void applyStyle(nextapp.echo.Style style)
nextapp.echo.Component
style names can be used as well.
applyStyle
in interface Scrollable
applyStyle
in class EchoPointComponent
Component.applyStyle(nextapp.echo.Style)
public nextapp.echo.Color getBorderColor()
Color
of the WizardPane's
border.public int getBorderSize()
WizardPane's
border.public nextapp.echo.Button getCancelButton()
WizardPane
.
public nextapp.echo.Component getComponentAt(int index)
Component
at the specified index.public int getCount()
WizardPane
.
public nextapp.echo.Button getFinishButton()
WizardPane
.
public TitleBar getFooter()
WizardPane
public java.lang.String getFooterAt(int index)
public int getHeight()
WizardPane
. If this value
is -1, then no height will be used.
getHeight
in interface Scrollable
public nextapp.echo.Insets getInsets()
public SingleSelectionModel getModel()
WizardPane
.
public nextapp.echo.Button getNextButton()
WizardPane
.
public int getPlacement()
WizardPane
public nextapp.echo.Button getPreviousButton()
WizardPane
.
public int getScrollBarPolicy()
getScrollBarPolicy
in interface Scrollable
public int getScrollBarX()
getScrollBarX
in interface Scrollable
public int getScrollBarY()
getScrollBarY
in interface Scrollable
public nextapp.echo.Component getSelectedComponent()
Component
at the currently selected index or null if
none is currently selected.public int getSelectedIndex()
public TitleBar getTitle()
WizardPane
public java.lang.String getTitleAt(int index)
public int getWidth()
WizardPane
. If this value
is -1, then no width will be used.
getWidth
in interface Scrollable
public int indexOfComponent(nextapp.echo.Component c)
Component
or -1 if it is not found
public int indexOfTitle(java.lang.String title)
public void insert(java.lang.String title, nextapp.echo.Component component, int index)
public void insert(java.lang.String title, java.lang.String footer, nextapp.echo.Component component, int index)
public boolean isFinishButtonOnLastOnly()
public void remove(nextapp.echo.Component c)
WizardPane
at represented by the Component c
public void remove(int index)
WizardPane
at the specified index.
public void removeAll()
WizardPane
.
public void removeChangeListener(nextapp.echo.event.ChangeListener l)
l
- the ChangeListener to removepublic void removeComponentAt(int index)
WizardPane
at the specified index.
public void removeWizardNavigationListener(WizardNavigationListener l)
WizardNavigationListener
to the WizardPane.
l
- The ChangeListener
to be added.protected void reRegisterComponents(nextapp.echo.Component oldValue, nextapp.echo.Component newValue)
oldValue
- - the old component to remove - can be nullnewValue
- - the new component to add - can be nullpublic void setBorderColor(nextapp.echo.Color newValue)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BORDER_COLOR_CHANGED_PROPERTY
public void setBorderSize(int newBorderSize)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BORDER_SIZE_CHANGED_PROPERTY
public void setCancelButton(nextapp.echo.Button newButton)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BUTTONS_CHANGED_PROPERTY
public void setComponentAt(int index, nextapp.echo.Component component)
Component
at the specified index
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.COMPONENT_CHANGED_PROPERTY
public void setEnabled(boolean newValue)
Component.setEnabled(boolean)
public void setFinishButton(nextapp.echo.Button newButton)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BUTTONS_CHANGED_PROPERTY
public void setFinishButtonOnLastOnly(boolean newFinishButtonOnLastOnly)
newFinishButtonOnLastOnly
- booleanpublic void setFooter(TitleBar newFooterBar)
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.FOOTERBAR_CHANGED_PROPERTY
public void setFooterAt(int index, java.lang.String footerText)
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.FOOTER_CHANGED_PROPERTY
public void setHeight(int newValue)
WizardPane
. If this
value is -1, then no height will be used.
Note that this is the height of the contents of the WizardPane not the outside of the Wizard Pane. This allows scrolling within the contents of the wizard pane.
This methods fires a PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.HEIGHT_CHANGED_PROPERTY
setHeight
in interface Scrollable
public void setInsets(nextapp.echo.Insets newValue)
WizardPane
newValue
- An insets object that specifies the size of each margin
of this WizardPane
public void setModel(SingleSelectionModel model)
WizardPane
.
public void setNextButton(nextapp.echo.Button newButton)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BUTTONS_CHANGED_PROPERTY
public void setPlacement(int newPlacement)
WizardPane
newPlacement
- the placement of the buttons
can be one of the following values.
public void setPreviousButton(nextapp.echo.Button newButton)
WizardPane
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.BUTTONS_CHANGED_PROPERTY
public void setScrollBarPolicy(int newScrollBarPolicy)
setScrollBarPolicy
in interface Scrollable
public void setScrollBarX(int newValue)
setScrollBarX
in interface Scrollable
newValue
- The new position of the horizontal scroll bar, in pixels.public void setScrollBarY(int newValue)
setScrollBarY
in interface Scrollable
newValue
- The new position of the vertical scroll bar, in pixels.public void setSelectedIndex(int index)
WizardPane
.
public void setTitle(TitleBar newTitleBar)
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.TITLEBAR_CHANGED_PROPERTY
public void setTitleAt(int index, java.lang.String title)
PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.TITLE_CHANGED_PROPERTY
public void setWidth(int newValue)
WizardPane
. If this
value is -1, then no width will be used.
Note that this is the height of the contents of the WizardPane not the outside of the Wizard Pane. This allows scrolling within the contents of the wizard pane.
This methods fires a PropertyChangeEvent
with a
getPropertyName()
value of
WizardPane.WIDTH_CHANGED_PROPERTY
setWidth
in interface Scrollable
public void validate()
validate
in class EchoPointComponent
Component.validate()
public java.lang.Object set(java.lang.reflect.Field field, java.lang.Object newValue) throws java.lang.Exception
ReflectionSetter
public Object set(Field f, Object newValue) throws Exception { Object oldValue = f.get(this); f.set(this,newValue); return oldValue; }
set
in interface ReflectionSetter
field
- - the field to be setnewValue
- - the new value to be set
java.lang.Exception
ReflectionSetter.set(Field, Object)
|
EchoPoint 1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |