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)
IPenDatasourceaddPen in interface IPenDatasourcepublic Dataset getDataset()
IPenDatasourcegetDataset in interface IPenDatasourceprotected void setDataset(Dataset dataset)
protected void setDatasetLater(Dataset dataset)
public int getNumDatapoints()
IPenDatasourcegetNumDatapoints in interface IPenDatasourceprotected long getMillisRange(PenData source)
public void initRefs(java.util.Map<java.lang.String,PenData> allPens)
IPenDatasourceinitRefs in interface IPenDatasourcepublic void shutdown()
IPenDatasourceshutdown in interface IPenDatasourcepublic void startup(PMIEasyChart chart)
IPenDatasourcestartup in interface IPenDatasourceprotected void warn(java.lang.String msg)
public boolean isZoomTracking()
IPenDatasourceisZoomTracking in interface IPenDatasource