public interface HistoryService
Modifier and Type | Method and Description |
---|---|
int |
getEarliestHistoryEntryVersionGtEqDate(long structureId,
long timestamp)
Returns the
HistoryEntry.getVersion() of the earliest history entry which timestamp >=
If there is no such history entry, returns 0. |
int |
getEntryCount(long structureId) |
int |
getEntryCountGtEqDate(long structureId,
long timestamp) |
ForestVersion |
getForestVersion(long structureId,
int version) |
List<HistoryEntry> |
getHistoryEntries(long structureId,
int versionFrom,
int versionTo)
Returns history entries for the specified structure that have versions in the specified range.
|
void |
getHistoryEntries(long structureId,
int versionFrom,
int versionTo,
HistoryConsumer consumer) |
List<HistoryEntry> |
getHistoryEntriesWithoutChanges(long structureId,
int versionFrom,
int versionTo)
Lightweight version of
getHistoryEntries(long, int, int) which does not
fetch changes, works much faster. |
int |
getLatestHistoryEntryVersion(long structureId)
Returns the
version of the latest history entry for the specified structure. |
void |
queryActivity(HistoryQuery hq,
int limit,
HistoryConsumer consumer)
'Streams' results of history query to consumer.
|
void |
queryActivity(HistoryQuery hq,
int limit,
int changesLimit,
LimitedHistoryConsumer consumer)
'Streams' results of history query to consumer while limiting the total amount of changes that are loaded per entry.
|
void queryActivity(HistoryQuery hq, int limit, HistoryConsumer consumer)
hq
- query.limit
- max number of HistoryEntry
that will be loaded.consumer
- receives HistoryEntry
results.void queryActivity(HistoryQuery hq, int limit, int changesLimit, LimitedHistoryConsumer consumer)
hq
- query.limit
- max number of HistoryEntry
that will be loaded.changesLimit
- max number of HistoryEntry.Change
loaded per HistoryEntry
.consumer
- receives HistoryEntry
and total number of HistoryEntry.Change
associated with it - which won't
have been completely loaded into the entry if the number exceeds changesLimit
void getHistoryEntries(long structureId, int versionFrom, int versionTo, HistoryConsumer consumer)
List<HistoryEntry> getHistoryEntries(long structureId, int versionFrom, int versionTo)
versionFrom
- minimum version, exclusiveversionTo
- maximum version, inclusiveList<HistoryEntry> getHistoryEntriesWithoutChanges(long structureId, int versionFrom, int versionTo)
getHistoryEntries(long, int, int)
which does not
fetch changes, works much faster.int getLatestHistoryEntryVersion(long structureId)
version
of the latest history entry for the specified structure.
If there are no history entries for the specified structure, returns 0.int getEarliestHistoryEntryVersionGtEqDate(long structureId, long timestamp)
HistoryEntry.getVersion()
of the earliest history entry which timestamp >=
If there is no such history entry, returns 0.int getEntryCount(long structureId)
int getEntryCountGtEqDate(long structureId, long timestamp)
ForestVersion getForestVersion(long structureId, int version) throws StructureException
structureId
- structure IDversion
- versionForestVersion
containing the full forest and the history entry
for the given versionStructureException
- if the structure does not exist or is inaccessible;
if there is no such version (including intermittent versions for which there is
no history entry)Copyright © 2024 Tempo Software. All Rights Reserved.