public class DataStoreAccesor extends AbstractValueSource
| Constructor and Description |
|---|
DataStoreAccesor(java.io.File basePath,
DataFilePool pool) |
| Modifier and Type | Method and Description |
|---|---|
static DataStoreAccesor |
create(java.io.File basePath,
long time,
java.util.concurrent.TimeUnit unit,
int count,
DataFilePool pool) |
void |
dispose() |
int |
getCount()
Get the number of slices configured
|
long |
getTimeSlice()
Get the time slice in milliseconds
|
protected void |
giveBack(org.eclipse.scada.hds.DataStoreAccesor.AccessorWrapper wrapper) |
void |
insertHeartbeat(java.util.Date date)
Insert a marker that the data input mechanism was alive at the provided
time
|
void |
insertValue(double value,
java.util.Date date,
boolean error,
boolean manual) |
protected void |
insertValue(double value,
java.util.Date date,
boolean error,
boolean manual,
boolean heartbeat) |
void |
purge()
Delete data files that are out of range
|
protected void |
take(org.eclipse.scada.hds.DataStoreAccesor.AccessorWrapper wrapper) |
boolean |
visit(ValueVisitor visitor,
java.util.Date start,
java.util.Date end)
Visit values
|
addListener, notifyChange, removeListenerpublic DataStoreAccesor(java.io.File basePath,
DataFilePool pool)
throws java.lang.Exception
java.lang.Exceptionpublic int getCount()
public long getTimeSlice()
protected void take(org.eclipse.scada.hds.DataStoreAccesor.AccessorWrapper wrapper)
protected void giveBack(org.eclipse.scada.hds.DataStoreAccesor.AccessorWrapper wrapper)
protected void insertValue(double value,
java.util.Date date,
boolean error,
boolean manual,
boolean heartbeat)
throws java.lang.Exception
java.lang.Exceptionpublic void insertValue(double value,
java.util.Date date,
boolean error,
boolean manual)
throws java.lang.Exception
java.lang.Exceptionpublic void insertHeartbeat(java.util.Date date)
throws java.lang.Exception
date - the date of the markerjava.lang.Exception - thrown if anything goes wrongpublic boolean visit(ValueVisitor visitor, java.util.Date start, java.util.Date end)
visitor - the visitorstart - the start rangeend - the end rangetrue if more should be read, false
otherwisepublic void purge()
public static DataStoreAccesor create(java.io.File basePath, long time, java.util.concurrent.TimeUnit unit, int count, DataFilePool pool) throws java.lang.Exception
java.lang.Exceptionpublic void dispose()
Copyright (c) IBH SYSTEMS GmbH and others 2010, 2013.
All rights reserved. This program and the accompanying materials
are made available under the terms of the
Eclipse Public License v1.0