Gephi Toolkit Javadoc

org.gephi.datalab.impl
Class DataTablesControllerImpl

java.lang.Object
  extended by org.gephi.datalab.impl.DataTablesControllerImpl
All Implemented Interfaces:
DataTablesController, DataTablesEventListener

public class DataTablesControllerImpl
extends java.lang.Object
implements DataTablesController

Implementation of the DataTablesController interface declared in the Data Laboratory API.

Author:
Eduardo Ramos
See Also:
DataTablesController

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.gephi.datalab.api.DataTablesEventListener
DataTablesEventListener.ExportMode
 
Constructor Summary
DataTablesControllerImpl()
           
 
Method Summary
 void exportCurrentTable(DataTablesEventListener.ExportMode exportMode)
          Requests to exports current table being shown as a file.
 DataTablesEventListener getDataTablesEventListener()
          Returns the current registered DataTablesEventListener.
 Edge[] getEdgeTableSelection()
          Request the tables implementation to provide the selected edges in edges table.
 Node[] getNodeTableSelection()
          Request the tables implementation to provide the selected nodes in nodes table.
 boolean isDataTablesReady()
          Indicates if Data Table UI is registered as a listener of the events created by this controller.
 boolean isEdgeTableMode()
          Checks if the data tables implementation is showing edges table
 boolean isNodeTableMode()
          Checks if the data tables implementation is showing nodes table
 boolean isShowEdgesNodesLabels()
          Checks if the data tables implementation is showing edges nodes (source and target) labels at the moment.
 boolean isShowOnlyVisible()
          Checks if the data tables implementation is showing only visible elements (nodes or edges) in the graph at the moment.
 boolean isTimeIntervalGraphics()
          Checks if the data tables implementation is showing time intervals as graphics at the moment.
 boolean isUseSparklines()
          Checks if the data tables implementation is showing number lists and dynamic numbers as sparklines at the moment.
 void refreshCurrentTable()
          Requests the tables implementation to refresh the data of the table being shown.
 void selectEdgesTable()
          Requests the tables implementation to show edges table.
 void selectNodesTable()
          Requests the tables implementation to show nodes table.
 void selectTable(AttributeTable table)
          Request the tables implementation to show the given table (nodes or edges table)
 void setDataTablesEventListener(DataTablesEventListener listener)
          Register a listener for these requests.
 void setEdgeTableSelection(Edge[] edges)
          Requests the tables implementation to adapt the edges table row selection to the specified edges.
 void setNodeTableSelection(Node[] nodes)
          Requests the tables implementation to adapt the nodes table row selection to the specified nodes.
 void setShowEdgesNodesLabels(boolean showEdgesNodesLabels)
          Requests the tables implementation to show edges nodes (source and target).
 void setShowOnlyVisible(boolean showOnlyVisible)
          Requests the tables implementation to show only visible elements or not.
 void setTimeIntervalGraphics(boolean timeIntervalGraphics)
          Requests the tables implementation to show time intervals as graphics.
 void setUseSparklines(boolean useSparklines)
          Requests the tables implementation to show number lists and dynamic numbers as sparklines.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataTablesControllerImpl

public DataTablesControllerImpl()
Method Detail

setDataTablesEventListener

public void setDataTablesEventListener(DataTablesEventListener listener)
Description copied from interface: DataTablesController
Register a listener for these requests.

Specified by:
setDataTablesEventListener in interface DataTablesController
Parameters:
listener - Instance of DataTablesEventListener

getDataTablesEventListener

public DataTablesEventListener getDataTablesEventListener()
Description copied from interface: DataTablesController
Returns the current registered DataTablesEventListener. It can be null if it is still not activated or there is no active workspace.

Specified by:
getDataTablesEventListener in interface DataTablesController
Returns:
Current listener or null

isDataTablesReady

public boolean isDataTablesReady()
Description copied from interface: DataTablesController
Indicates if Data Table UI is registered as a listener of the events created by this controller.

Specified by:
isDataTablesReady in interface DataTablesController
Returns:
True if Data Table UI is prepared, false otherwise

selectNodesTable

public void selectNodesTable()
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show nodes table.

Specified by:
selectNodesTable in interface DataTablesEventListener

selectEdgesTable

public void selectEdgesTable()
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show edges table.

Specified by:
selectEdgesTable in interface DataTablesEventListener

selectTable

public void selectTable(AttributeTable table)
Description copied from interface: DataTablesController
Request the tables implementation to show the given table (nodes or edges table)

Specified by:
selectTable in interface DataTablesController
Parameters:
table - Table to show

refreshCurrentTable

public void refreshCurrentTable()
Description copied from interface: DataTablesEventListener
Requests the tables implementation to refresh the data of the table being shown.

Specified by:
refreshCurrentTable in interface DataTablesEventListener

setNodeTableSelection

public void setNodeTableSelection(Node[] nodes)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to adapt the nodes table row selection to the specified nodes.

Specified by:
setNodeTableSelection in interface DataTablesEventListener
Parameters:
nodes - Nodes to select

setEdgeTableSelection

public void setEdgeTableSelection(Edge[] edges)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to adapt the edges table row selection to the specified edges.

Specified by:
setEdgeTableSelection in interface DataTablesEventListener
Parameters:
edges - Edges to select

getNodeTableSelection

public Node[] getNodeTableSelection()
Description copied from interface: DataTablesEventListener
Request the tables implementation to provide the selected nodes in nodes table.

Specified by:
getNodeTableSelection in interface DataTablesEventListener
Returns:
Array of selected nodes

getEdgeTableSelection

public Edge[] getEdgeTableSelection()
Description copied from interface: DataTablesEventListener
Request the tables implementation to provide the selected edges in edges table.

Specified by:
getEdgeTableSelection in interface DataTablesEventListener
Returns:
Array of selected edges

isNodeTableMode

public boolean isNodeTableMode()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing nodes table

Specified by:
isNodeTableMode in interface DataTablesEventListener
Returns:
True if nodes table is being shown, false otherwise

isEdgeTableMode

public boolean isEdgeTableMode()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing edges table

Specified by:
isEdgeTableMode in interface DataTablesEventListener
Returns:
True if edges table is being shown, false otherwise

isShowOnlyVisible

public boolean isShowOnlyVisible()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing only visible elements (nodes or edges) in the graph at the moment.

Specified by:
isShowOnlyVisible in interface DataTablesEventListener
Returns:
True if only visible elements are being shown, false otherwise

setShowOnlyVisible

public void setShowOnlyVisible(boolean showOnlyVisible)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show only visible elements or not.

Specified by:
setShowOnlyVisible in interface DataTablesEventListener
Parameters:
showOnlyVisible - Indicates if only visible elements have to be shown in table

exportCurrentTable

public void exportCurrentTable(DataTablesEventListener.ExportMode exportMode)
Description copied from interface: DataTablesEventListener
Requests to exports current table being shown as a file.

Specified by:
exportCurrentTable in interface DataTablesEventListener
Parameters:
exportMode - ExportMode - CSV only for now

isUseSparklines

public boolean isUseSparklines()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing number lists and dynamic numbers as sparklines at the moment.

Specified by:
isUseSparklines in interface DataTablesEventListener
Returns:
True if sparklines are on, false otherwise

setUseSparklines

public void setUseSparklines(boolean useSparklines)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show number lists and dynamic numbers as sparklines.

Specified by:
setUseSparklines in interface DataTablesEventListener
Parameters:
useSparklines - Indicates if sparklines should be used

isTimeIntervalGraphics

public boolean isTimeIntervalGraphics()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing time intervals as graphics at the moment.

Specified by:
isTimeIntervalGraphics in interface DataTablesEventListener
Returns:
True if sparklines are on, false otherwise

setTimeIntervalGraphics

public void setTimeIntervalGraphics(boolean timeIntervalGraphics)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show time intervals as graphics.

Specified by:
setTimeIntervalGraphics in interface DataTablesEventListener
Parameters:
timeIntervalGraphics - Indicates if time interval graphics should be used

isShowEdgesNodesLabels

public boolean isShowEdgesNodesLabels()
Description copied from interface: DataTablesEventListener
Checks if the data tables implementation is showing edges nodes (source and target) labels at the moment.

Specified by:
isShowEdgesNodesLabels in interface DataTablesEventListener
Returns:
True if edges nodes lables are shown, false otherwise

setShowEdgesNodesLabels

public void setShowEdgesNodesLabels(boolean showEdgesNodesLabels)
Description copied from interface: DataTablesEventListener
Requests the tables implementation to show edges nodes (source and target).

Specified by:
setShowEdgesNodesLabels in interface DataTablesEventListener
Parameters:
showEdgesNodesLabels - Indicates if edges nodes labels should be shown

Gephi Toolkit Javadoc