com.esri.arcgis.arcmapui
Class TableWindow

java.lang.Object
  extended by com.esri.arcgis.arcmapui.TableWindow
All Implemented Interfaces:
IDataWindow, IDataWindow2, ITableWindow, ITableWindow2, ITableWindow3, ITimeDisplayEvents, com.esri.arcgis.interop.RemoteObjRef, Serializable, EventListener

public class TableWindow
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, ITableWindow, IDataWindow, IDataWindow2, ITableWindow2, ITableWindow3, ITimeDisplayEvents

Window to display Tables in ArcMap.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

See Also:
Serialized Form

Constructor Summary
TableWindow()
          Constructs a TableWindow using ArcGIS Engine.
TableWindow(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
TableWindow theTableWindow = (TableWindow) obj;
 
Method Summary
 void addIDataWindowEventsListener(IDataWindowEvents theListener)
          addIDataWindowEventsListener.
 void destroy()
          Close and destroy the window.
 void displayTimeChanged(ITimeDisplayEventsDisplayTimeChangedEvent theEvent)
          Notifies clients when display time changed.
 boolean equals(Object o)
          Compare this object with another
 void findOpenTableWindows(ISet[] pTableWindows)
          Gets all the open table windows.
 ITableWindow findViaFeatureLayer(IFeatureLayer pFeatureLayer, boolean showSelected)
          Is table (of a featurelayer) already being displayed.
 ITableWindow findViaLayer(ILayer pLayer)
          Is table (of a layer) already being displayed.
 ITableWindow findViaStandaloneTable(IStandaloneTable pStandaloneTable)
          Is table (of a standalonetable) already being displayed.
 ITableWindow findViaTable(ITable pTable, boolean showSelected)
          Is table already being displayed.
 ITableWindow getActiveTableWindow()
          Gets the active table window.
static String getClsid()
          getClsid.
 IFeatureLayer getFeatureLayer()
          Setup feature class to view/edit.
 int getHWnd()
          The window's handle.
 ILayer getLayer()
          Setup layer attributes to view.
 ISelectionSet getSelectionSet()
          Current s1election set of the table.
 IStandaloneTable getStandaloneTable()
          The standalone table to view/edit.
 ITable getTable()
          Setup table to view/edit.
 ITableControl getTableControl()
          The table control.
 int getTableSelectionAction()
          Action to perform when table selections are made.
 String getTag()
          For developer use.
 int hashCode()
          the hashcode for this object
 boolean isDockable()
          Indicates if the window is dockable.
 boolean isEnableContextMenu()
          Indicates if the context menu should be enabled.
 boolean isOpen()
          Indicates if the window is open in the table window docking pane.
 boolean isShowSelected()
          Indicates whether to show only features that are selected.
 boolean isVisible()
          Indicates if the window is visible.
 void putPosition(int left, int top, int right, int bottom)
          The window's position in screen pixels.
 void queryPosition(int[] left, int[] top, int[] right, int[] bottom)
          The window's position in screen pixels.
 void refresh()
          Cause the window to redraw.
 void removeIDataWindowEventsListener(IDataWindowEvents theListener)
          removeIDataWindowEventsListener.
 void setApplicationByRef(Object rhs1)
          Provides the window with a reference to the application.
 void setEnableContextMenu(boolean enable)
          Indicates if the context menu should be enabled.
 void setFeatureLayerByRef(IFeatureLayer ppFeatureLayer)
          Setup feature class to view/edit.
 void setLayerByRef(ILayer ppLayer)
          Setup layer attributes to view.
 void setShowAliasNamesInColumnHeadings(boolean rhs1)
          Show alias names or the real field name in column headings.
 void setShowSelected(boolean pShowSelected)
          Indicates whether to show only features that are selected.
 void setStandaloneTableByRef(IStandaloneTable table)
          The standalone table to view/edit.
 void setTableByRef(ITable ppTable)
          Setup table to view/edit.
 void setTableSelectionAction(int pAction)
          Action to perform when table selections are made.
 void setTag(String tag)
          For developer use.
 void show(boolean show)
          Indicates if the window is shown.
 void updateSelection(ISelectionSet pSelection)
          Updates current table selection.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

TableWindow

public TableWindow()
            throws IOException,
                   UnknownHostException
Constructs a TableWindow using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

TableWindow

public TableWindow(Object obj)
            throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
TableWindow theTableWindow = (TableWindow) obj;

Construct a TableWindow using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to TableWindow.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

addIDataWindowEventsListener

public void addIDataWindowEventsListener(IDataWindowEvents theListener)
                                  throws IOException
addIDataWindowEventsListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.arcmapui.IDataWindowEvents interface.
Throws:
IOException - If there are communications problems.

removeIDataWindowEventsListener

public void removeIDataWindowEventsListener(IDataWindowEvents theListener)
                                     throws IOException
removeIDataWindowEventsListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.arcmapui.IDataWindowEvents interface.
Throws:
IOException - If there are communications problems.

setTableByRef

public void setTableByRef(ITable ppTable)
                   throws IOException,
                          AutomationException
Setup table to view/edit.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setTableByRef in interface ITableWindow
Parameters:
ppTable - A reference to a com.esri.arcgis.geodatabase.ITable (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTable

public ITable getTable()
                throws IOException,
                       AutomationException
Setup table to view/edit.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getTable in interface ITableWindow
Returns:
A reference to a com.esri.arcgis.geodatabase.ITable
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFeatureLayerByRef

public void setFeatureLayerByRef(IFeatureLayer ppFeatureLayer)
                          throws IOException,
                                 AutomationException
Setup feature class to view/edit.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setFeatureLayerByRef in interface ITableWindow
Parameters:
ppFeatureLayer - A reference to a com.esri.arcgis.carto.IFeatureLayer (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFeatureLayer

public IFeatureLayer getFeatureLayer()
                              throws IOException,
                                     AutomationException
Setup feature class to view/edit.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getFeatureLayer in interface ITableWindow
Returns:
A reference to a com.esri.arcgis.carto.IFeatureLayer
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setTableSelectionAction

public void setTableSelectionAction(int pAction)
                             throws IOException,
                                    AutomationException
Action to perform when table selections are made.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setTableSelectionAction in interface ITableWindow
Specified by:
setTableSelectionAction in interface ITableWindow2
Parameters:
pAction - A com.esri.arcgis.geodatabaseui.esriTableSelectionActions constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTableSelectionAction

public int getTableSelectionAction()
                            throws IOException,
                                   AutomationException
Action to perform when table selections are made.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getTableSelectionAction in interface ITableWindow
Specified by:
getTableSelectionAction in interface ITableWindow2
Returns:
A com.esri.arcgis.geodatabaseui.esriTableSelectionActions constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setShowSelected

public void setShowSelected(boolean pShowSelected)
                     throws IOException,
                            AutomationException
Indicates whether to show only features that are selected.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setShowSelected in interface ITableWindow
Specified by:
setShowSelected in interface ITableWindow2
Parameters:
pShowSelected - The pShowSelected (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isShowSelected

public boolean isShowSelected()
                       throws IOException,
                              AutomationException
Indicates whether to show only features that are selected.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
isShowSelected in interface ITableWindow
Specified by:
isShowSelected in interface ITableWindow2
Returns:
The pShowSelected
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findViaFeatureLayer

public ITableWindow findViaFeatureLayer(IFeatureLayer pFeatureLayer,
                                        boolean showSelected)
                                 throws IOException,
                                        AutomationException
Is table (of a featurelayer) already being displayed.

Remarks

This method returns a reference to the TableWindow of the FeatureLayer referenced by pFeatureLayer. Set ShowSelected = True if you wish to show only features that are selected.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
findViaFeatureLayer in interface ITableWindow
Parameters:
pFeatureLayer - A reference to a com.esri.arcgis.carto.IFeatureLayer (in)
showSelected - The showSelected (in)
Returns:
A reference to a com.esri.arcgis.arcmapui.ITableWindow
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findViaTable

public ITableWindow findViaTable(ITable pTable,
                                 boolean showSelected)
                          throws IOException,
                                 AutomationException
Is table already being displayed.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
findViaTable in interface ITableWindow
Parameters:
pTable - A reference to a com.esri.arcgis.geodatabase.ITable (in)
showSelected - The showSelected (in)
Returns:
A reference to a com.esri.arcgis.arcmapui.ITableWindow
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSelectionSet

public ISelectionSet getSelectionSet()
                              throws IOException,
                                     AutomationException
Current s1election set of the table. Only valid for tables showing all rows.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getSelectionSet in interface ITableWindow
Specified by:
getSelectionSet in interface ITableWindow2
Returns:
A reference to a com.esri.arcgis.geodatabase.ISelectionSet
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

updateSelection

public void updateSelection(ISelectionSet pSelection)
                     throws IOException,
                            AutomationException
Updates current table selection. Does not update Mx feature layer selection.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
updateSelection in interface ITableWindow
Specified by:
updateSelection in interface ITableWindow2
Parameters:
pSelection - A reference to a com.esri.arcgis.geodatabase.ISelectionSet (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setShowAliasNamesInColumnHeadings

public void setShowAliasNamesInColumnHeadings(boolean rhs1)
                                       throws IOException,
                                              AutomationException
Show alias names or the real field name in column headings. Default False.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setShowAliasNamesInColumnHeadings in interface ITableWindow
Specified by:
setShowAliasNamesInColumnHeadings in interface ITableWindow2
Parameters:
rhs1 - The rhs1 (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTableControl

public ITableControl getTableControl()
                              throws IOException,
                                     AutomationException
The table control. Table needs to be showing before you can get a valid pointer.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getTableControl in interface ITableWindow
Specified by:
getTableControl in interface ITableWindow2
Returns:
A reference to a com.esri.arcgis.geodatabaseui.ITableControl
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setApplicationByRef

public void setApplicationByRef(Object rhs1)
                         throws IOException,
                                AutomationException
Provides the window with a reference to the application.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setApplicationByRef in interface IDataWindow
Specified by:
setApplicationByRef in interface IDataWindow2
Parameters:
rhs1 - A reference to another Automation Object (IDispatch) (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getHWnd

public int getHWnd()
            throws IOException,
                   AutomationException
The window's handle.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getHWnd in interface IDataWindow
Specified by:
getHWnd in interface IDataWindow2
Returns:
The hWnd (A COM typedef)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryPosition

public void queryPosition(int[] left,
                          int[] top,
                          int[] right,
                          int[] bottom)
                   throws IOException,
                          AutomationException
The window's position in screen pixels.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
queryPosition in interface IDataWindow
Specified by:
queryPosition in interface IDataWindow2
Parameters:
left - The left (out: use single element array)
top - The top (out: use single element array)
right - The right (out: use single element array)
bottom - The bottom (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

putPosition

public void putPosition(int left,
                        int top,
                        int right,
                        int bottom)
                 throws IOException,
                        AutomationException
The window's position in screen pixels.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
putPosition in interface IDataWindow
Specified by:
putPosition in interface IDataWindow2
Parameters:
left - The left (in)
top - The top (in)
right - The right (in)
bottom - The bottom (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isVisible

public boolean isVisible()
                  throws IOException,
                         AutomationException
Indicates if the window is visible.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
isVisible in interface IDataWindow
Specified by:
isVisible in interface IDataWindow2
Returns:
The isVisible
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isDockable

public boolean isDockable()
                   throws IOException,
                          AutomationException
Indicates if the window is dockable.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
isDockable in interface IDataWindow
Specified by:
isDockable in interface IDataWindow2
Returns:
The isVisible
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

show

public void show(boolean show)
          throws IOException,
                 AutomationException
Indicates if the window is shown.

Description

Show specifies whether the data window should be shown or hidden. Use True to show the window and False to hide the window.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
show in interface IDataWindow
Specified by:
show in interface IDataWindow2
Parameters:
show - The show (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

refresh

public void refresh()
             throws IOException,
                    AutomationException
Cause the window to redraw.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
refresh in interface IDataWindow
Specified by:
refresh in interface IDataWindow2
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTag

public String getTag()
              throws IOException,
                     AutomationException
For developer use.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getTag in interface IDataWindow2
Returns:
The tag
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setTag

public void setTag(String tag)
            throws IOException,
                   AutomationException
For developer use.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setTag in interface IDataWindow2
Parameters:
tag - The tag (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isEnableContextMenu

public boolean isEnableContextMenu()
                            throws IOException,
                                   AutomationException
Indicates if the context menu should be enabled.

Product Availability

Available with ArcGIS Desktop.

Specified by:
isEnableContextMenu in interface IDataWindow2
Returns:
The enable
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setEnableContextMenu

public void setEnableContextMenu(boolean enable)
                          throws IOException,
                                 AutomationException
Indicates if the context menu should be enabled.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setEnableContextMenu in interface IDataWindow2
Parameters:
enable - The enable (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

destroy

public void destroy()
             throws IOException,
                    AutomationException
Close and destroy the window.

Product Availability

Available with ArcGIS Desktop.

Specified by:
destroy in interface IDataWindow2
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setLayerByRef

public void setLayerByRef(ILayer ppLayer)
                   throws IOException,
                          AutomationException
Setup layer attributes to view.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setLayerByRef in interface ITableWindow2
Parameters:
ppLayer - A reference to a com.esri.arcgis.carto.ILayer (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getLayer

public ILayer getLayer()
                throws IOException,
                       AutomationException
Setup layer attributes to view.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getLayer in interface ITableWindow2
Returns:
A reference to a com.esri.arcgis.carto.ILayer
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setStandaloneTableByRef

public void setStandaloneTableByRef(IStandaloneTable table)
                             throws IOException,
                                    AutomationException
The standalone table to view/edit.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setStandaloneTableByRef in interface ITableWindow2
Parameters:
table - A reference to a com.esri.arcgis.carto.IStandaloneTable (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getStandaloneTable

public IStandaloneTable getStandaloneTable()
                                    throws IOException,
                                           AutomationException
The standalone table to view/edit.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getStandaloneTable in interface ITableWindow2
Returns:
A reference to a com.esri.arcgis.carto.IStandaloneTable
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findViaLayer

public ITableWindow findViaLayer(ILayer pLayer)
                          throws IOException,
                                 AutomationException
Is table (of a layer) already being displayed.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
findViaLayer in interface ITableWindow2
Parameters:
pLayer - A reference to a com.esri.arcgis.carto.ILayer (in)
Returns:
A reference to a com.esri.arcgis.arcmapui.ITableWindow
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findViaStandaloneTable

public ITableWindow findViaStandaloneTable(IStandaloneTable pStandaloneTable)
                                    throws IOException,
                                           AutomationException
Is table (of a standalonetable) already being displayed.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
findViaStandaloneTable in interface ITableWindow2
Parameters:
pStandaloneTable - A reference to a com.esri.arcgis.carto.IStandaloneTable (in)
Returns:
A reference to a com.esri.arcgis.arcmapui.ITableWindow
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isOpen

public boolean isOpen()
               throws IOException,
                      AutomationException
Indicates if the window is open in the table window docking pane.

Product Availability

Available with ArcGIS Desktop.

Specified by:
isOpen in interface ITableWindow3
Returns:
The pIsOpen
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findOpenTableWindows

public void findOpenTableWindows(ISet[] pTableWindows)
                          throws IOException,
                                 AutomationException
Gets all the open table windows.

Product Availability

Available with ArcGIS Desktop.

Specified by:
findOpenTableWindows in interface ITableWindow3
Parameters:
pTableWindows - A reference to a com.esri.arcgis.system.ISet (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getActiveTableWindow

public ITableWindow getActiveTableWindow()
                                  throws IOException,
                                         AutomationException
Gets the active table window.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getActiveTableWindow in interface ITableWindow3
Returns:
A reference to a com.esri.arcgis.arcmapui.ITableWindow
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

displayTimeChanged

public void displayTimeChanged(ITimeDisplayEventsDisplayTimeChangedEvent theEvent)
                        throws IOException,
                               AutomationException
Notifies clients when display time changed.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
displayTimeChanged in interface ITimeDisplayEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.