public class AbstractCalculatedPenDatasource extends java.lang.Object implements IPenDatasource
Modifier and Type | Field and Description |
---|---|
protected PMIEasyChart |
chart |
protected Dataset |
dataset |
protected java.util.Set<PenDataset> |
datasets |
protected java.util.Date |
endDate
The configured end date.
|
protected LoggerEx |
log |
protected java.util.List<PenData> |
pens |
protected java.util.Date |
startDate
The starting date of the chart.
|
Modifier | Constructor and Description |
---|---|
protected |
AbstractCalculatedPenDatasource() |
Modifier and Type | Method and Description |
---|---|
void |
addPen(PenData pen)
Adds a pen to this datasource.
|
Dataset |
getDataset()
The underlying dataset that drives this datasource
|
protected long |
getMillisRange(PenData source)
Returns the range of millis between the first and last points in the given pen dataset
|
int |
getNumDatapoints()
Return the number of datapoints currently loaded in this source
|
void |
initRefs(java.util.Map<java.lang.String,PenData> allPens)
Gives the datasource a chance to install references to other pens
|
boolean |
isZoomTracking()
True if this datasource should be restarted when the zoom level changes.
|
protected void |
setDataset(Dataset dataset) |
protected void |
setDatasetLater(Dataset dataset) |
void |
shutdown()
Shuts this datasoure down, if it has re-occurring activity.
|
void |
startup(PMIEasyChart chart)
Start this datasouce up.
|
protected void |
warn(java.lang.String msg) |
protected Dataset dataset
protected java.util.List<PenData> pens
protected java.util.Set<PenDataset> datasets
protected PMIEasyChart chart
protected java.util.Date startDate
startup(PMIEasyChart)
protected java.util.Date endDate
startup(PMIEasyChart)
protected final LoggerEx log
public void addPen(PenData pen)
IPenDatasource
addPen
in interface IPenDatasource
public Dataset getDataset()
IPenDatasource
getDataset
in interface IPenDatasource
protected void setDataset(Dataset dataset)
protected void setDatasetLater(Dataset dataset)
public int getNumDatapoints()
IPenDatasource
getNumDatapoints
in interface IPenDatasource
protected long getMillisRange(PenData source)
public void initRefs(java.util.Map<java.lang.String,PenData> allPens)
IPenDatasource
initRefs
in interface IPenDatasource
public void shutdown()
IPenDatasource
shutdown
in interface IPenDatasource
public void startup(PMIEasyChart chart)
IPenDatasource
startup
in interface IPenDatasource
protected void warn(java.lang.String msg)
public boolean isZoomTracking()
IPenDatasource
isZoomTracking
in interface IPenDatasource