|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.refractions.udig.catalog.service.database.TableSelectionTab
public class TableSelectionTab
A composite that helps a user select a set of tables in a database. It provides various methods to for filtering the tables.
Nested Class Summary | |
---|---|
class |
TableSelectionTab.FilteringContentProvider
Filters the input based on the textbox and the button states in TableSelectionTab |
class |
TableSelectionTab.TableLabelProvider
Displays the postgis table name in the first column and the geometry type in the second. |
Constructor Summary | |
---|---|
TableSelectionTab(DatabaseServiceDialect dialect)
|
Method Summary | |
---|---|
void |
addListener(Listener modifyListener)
Fires an SWT.Modify method when something has changed that may change the state of the tab as recognizable by calling Tab.getParams(Map) and Tab.getResourceIDs(Map) . |
Control |
createControl(Composite parent,
int style)
Creates the control. |
|
getParams(java.util.Map<java.lang.String,java.io.Serializable> params)
Returns the connection parameters as known by the caller. |
java.util.Collection<java.net.URL> |
getResourceIDs(java.util.Map<java.lang.String,java.io.Serializable> params)
Return the ids of the selected IGeoResource (if needed) |
void |
init()
Called when the containing page has just been shown. |
boolean |
leavingPage()
Called by the PostgisConnectionPage as the page is about to be left if the tab is active |
void |
setTableInput(java.util.Collection<TableDescriptor> tables)
Sets the input in the table viewer so it will display the collection |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TableSelectionTab(DatabaseServiceDialect dialect)
Method Detail |
---|
public void init()
Tab
init
in interface Tab
public Control createControl(Composite parent, int style)
parent
- the parent compositestyle
- the style to pass to the top level composite.
public void setTableInput(java.util.Collection<TableDescriptor> tables)
tables
- the table information to display.publicgetParams(java.util.Map<java.lang.String,java.io.Serializable> params)
Tab
getParams
in interface Tab
params
- the basic parameters for connecting to a database. The tab can augment the params.
public boolean leavingPage()
Tab
PostgisConnectionPage
as the page is about to be left if the tab is active
There are two main use cases for this method. The first is to save settings for the next time the wizard is visited. The other is to perform some checks or do some loading that is too expensive to do every time isPageComplete() is called. For example a database wizard page might try to connect to the database in this method rather than isPageComplete() because it is such an expensive method to call.
If an expensive method is called make sure to run it in the container:
getContainer().run(true, cancelable, runnable);
leavingPage
in interface Tab
public java.util.Collection<java.net.URL> getResourceIDs(java.util.Map<java.lang.String,java.io.Serializable> params)
Tab
getResourceIDs
in interface Tab
params
- the params used for connecting to the database. It must be a valid set of Postgis params.
public void addListener(Listener modifyListener)
Tab
Tab.getParams(Map)
and Tab.getResourceIDs(Map)
.
When an event is fired the owner of the tab should call Tab.getParams(Map)
and Tab.getResourceIDs(Map)
again.
addListener
in interface Tab
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |