org.opensourcephysics.tools
Class DataColumn

java.lang.Object
  extended by javax.swing.table.AbstractTableModel
      extended by org.opensourcephysics.display.Dataset
          extended by org.opensourcephysics.tools.DataColumn
All Implemented Interfaces:
java.io.Serializable, javax.swing.table.TableModel, Data, Drawable, LogMeasurable, Measurable

public class DataColumn
extends Dataset

A Dataset that represents a single column in a DataToolTable. The x-column name is always "row" and the x-points are always row numbers.

Version:
1.0
Author:
Douglas Brown
See Also:
Serialized Form

Nested Class Summary
protected static class DataColumn.Loader
          A class to save and load DataColumn data in an XMLControl.
 
Field Summary
 
Fields inherited from class org.opensourcephysics.display.Dataset
AREA, BAR, CIRCLE, columnID, CUSTOM, customMarker, datasetID, errorBars, generalPath, index, maxPoints, NO_MARKER, PIXEL, POST, sorted, SQUARE, visible, xmax, xmaxLogscale, xmin, xminLogscale, xpoints, ymax, ymaxLogscale, ymin, yminLogscale, ypoints
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
DataColumn()
          Constructs a DataColumn.
 
Method Summary
static XML.ObjectLoader getLoader()
          Returns the XML.ObjectLoader for this class.
 void setPoints(double[] yPoints)
          Sets the y-column points.
 void setXColumnVisible(boolean b)
          Overrides Dataset.setXColumnVisible method.
 void setXYColumnNames(java.lang.String xName, java.lang.String yName)
          Overrides Dataset.setXYColumnNames method.
 void setXYColumnNames(java.lang.String xName, java.lang.String yName, java.lang.String name)
          Overrides Dataset.setXYColumnNames method.
 
Methods inherited from class org.opensourcephysics.display.Dataset
append, append, append, append, clear, convertTableColumnIndex, countColumnsVisible, draw, drawFilledPlot, drawLinePlot, drawScatterPlot, getColumnClass, getColumnCount, getColumnID, getColumnName, getColumnNames, getData2D, getData3D, getDataList, getDatasets, getEdgeColor, getFillColor, getFillColors, getID, getIndex, getLineColor, getLineColors, getMarkerShape, getMarkerSize, getName, getPoints, getRowCount, getValidXPoints, getValidYPoints, getValueAt, getVisible, getXColumnName, getXMax, getXMaxLogscale, getXMin, getXMinLogscale, getXPoints, getYColumnName, getYMax, getYMaxLogscale, getYMin, getYMinLogscale, getYPoints, insertionSort, isConnected, isMeasured, isSorted, isXColumnVisible, isYColumnVisible, moveDatum, read, recalculatePath, setColumnID, setConnected, setCustomMarker, setID, setLineColor, setMarkerColor, setMarkerColor, setMarkerColor, setMarkerShape, setMarkerSize, setMaximumPoints, setName, setSorted, setStride, setVisible, setYColumnVisible, toString, write
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DataColumn

public DataColumn()
Constructs a DataColumn.

Method Detail

setPoints

public void setPoints(double[] yPoints)
Sets the y-column points. The x-column points are always row numbers.

Parameters:
yPoints - the y-column data points

setXYColumnNames

public void setXYColumnNames(java.lang.String xName,
                             java.lang.String yName)
Overrides Dataset.setXYColumnNames method. The x-column name is always "row".

Overrides:
setXYColumnNames in class Dataset
Parameters:
xName - ignored
yName - the y-column name

setXYColumnNames

public void setXYColumnNames(java.lang.String xName,
                             java.lang.String yName,
                             java.lang.String name)
Overrides Dataset.setXYColumnNames method. The x-column name is always "row".

Overrides:
setXYColumnNames in class Dataset
Parameters:
xName - ignored
yName - the y-column name
name - the dataset name

setXColumnVisible

public void setXColumnVisible(boolean b)
Overrides Dataset.setXColumnVisible method. The x-column is never visible.

Overrides:
setXColumnVisible in class Dataset
Parameters:
b - ignored

getLoader

public static XML.ObjectLoader getLoader()
Returns the XML.ObjectLoader for this class.

Returns:
the object loader