public class ASCIIFileDataSource extends PollingDataSource
Modifier and Type | Field and Description |
---|---|
static int |
DATA_SOURCE_EXCEPTION_EVENT |
private org.apache.commons.logging.Log |
LOG |
static int |
POINT_READ_EXCEPTION_EVENT |
private ASCIIFileDataSourceVO<?> |
vo |
dataPoints, pointListChanged
addedChangedPoints, ATTR_DISCONNECTED_KEY, ATTR_UNRELIABLE_KEY, pointListChangeLock, removedPoints
Constructor and Description |
---|
ASCIIFileDataSource(ASCIIFileDataSourceVO<?> vo) |
Modifier and Type | Method and Description |
---|---|
protected void |
doPoll(long time) |
private long |
getTimestamp(ASCIIFilePointLocatorVO point,
java.lang.String arquivo) |
private MangoValue |
getValue(ASCIIFilePointLocatorVO point,
java.lang.String arquivo) |
private java.lang.String |
readFile(java.io.File file) |
void |
setPointValue(DataPointRT dataPoint,
PointValueTime valueTime,
SetPointSource source) |
beginPolling, joinTermination, scheduleTimeout, setPollingPeriod, terminate, updateChangedPoints
addDataPoint, forcePointRead, getExceptionMessage, getId, getName, getPersistentData, getSerialExceptionMessage, initialize, raiseEvent, relinquish, removeDataPoint, returnToNormal, setPersistentData
private final org.apache.commons.logging.Log LOG
public static final int POINT_READ_EXCEPTION_EVENT
public static final int DATA_SOURCE_EXCEPTION_EVENT
private final ASCIIFileDataSourceVO<?> vo
public ASCIIFileDataSource(ASCIIFileDataSourceVO<?> vo)
protected void doPoll(long time)
doPoll
in class PollingDataSource
private MangoValue getValue(ASCIIFilePointLocatorVO point, java.lang.String arquivo) throws java.lang.Exception
java.lang.Exception
private long getTimestamp(ASCIIFilePointLocatorVO point, java.lang.String arquivo) throws java.lang.Exception
java.lang.Exception
public void setPointValue(DataPointRT dataPoint, PointValueTime valueTime, SetPointSource source)
setPointValue
in class DataSourceRT
private java.lang.String readFile(java.io.File file)