public abstract class AbstractStorageImpl extends Object implements HistoricalItem, ValueSourceManager
| Modifier and Type | Class and Description |
|---|---|
protected static interface |
AbstractStorageImpl.QueryRunnable |
| Modifier and Type | Field and Description |
|---|---|
protected String |
id |
protected DataStoreAccesor |
nativeLevel |
protected Lock |
readLock |
protected ReadWriteLock |
rwLock |
protected Lock |
writeLock |
| Constructor and Description |
|---|
AbstractStorageImpl(File file,
DataFilePool pool,
ScheduledExecutorService queryExecutor,
ScheduledExecutorService eventExecutor) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addJob(FutureTask<Void> task) |
Query |
createQuery(QueryParameters parameters,
QueryListener listener,
boolean updateData)
Create a new query
|
void |
dispose() |
HistoricalItemInformation |
getInformation()
Get the item information
|
StorageInformation |
getStorageInformation() |
protected void |
handleStoreChanged(Date start,
Date end) |
protected void |
notifyData(double value,
Date timestamp,
boolean error,
boolean manual) |
void |
queryClosed(QueryImpl query) |
protected void |
removeJob(Future<Void> future) |
protected void |
runOnQuery(AbstractStorageImpl.QueryRunnable runnable) |
boolean |
visit(QueryParameters parameters,
ValueVisitor visitor)
Visit values
|
protected final String id
protected final DataStoreAccesor nativeLevel
protected final ReadWriteLock rwLock
protected final Lock writeLock
protected final Lock readLock
public AbstractStorageImpl(File file, DataFilePool pool, ScheduledExecutorService queryExecutor, ScheduledExecutorService eventExecutor) throws Exception
Exceptionprotected void addJob(FutureTask<Void> task)
public StorageInformation getStorageInformation()
public HistoricalItemInformation getInformation()
HistoricalItemgetInformation in interface HistoricalItemprotected void runOnQuery(AbstractStorageImpl.QueryRunnable runnable)
protected void notifyData(double value,
Date timestamp,
boolean error,
boolean manual)
public Query createQuery(QueryParameters parameters, QueryListener listener, boolean updateData)
HistoricalItemcreateQuery in interface HistoricalItemparameters - the initial query parameterslistener - the query listenerupdateData - if true then additional updates will be made by
the query when
data changes although the query is QueryState.COMPLETEnull if the query could be be
createdpublic void queryClosed(QueryImpl query)
queryClosed in interface ValueSourceManagerpublic boolean visit(QueryParameters parameters, ValueVisitor visitor)
ValueSourceManagervisit in interface ValueSourceManagerparameters - the parameters to visitvisitor - the visitortrue if the run was complete, false if
is was aborted by the visitorpublic void dispose()
Copyright © 2015 Eclipse SCADA Project. All rights reserved.