Package one.microstream.storage.types
Interface StorageEntity
-
- All Known Implementing Classes:
StorageEntity.Default
public interface StorageEntityPublic API level type of storage entity. Used for custom evaluators, filters, etc. Does intentionally not provide any means to load/access the entity's data or change any if its state. This is purely a querying interface, not a means to manipulate data via bypassing normal channels to do so.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classStorageEntity.Defaultstatic classStorageEntity.MaxObjectIdstatic classStorageEntity.MinObjectId
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longcachedDataLength()The length this entity occupies in the cache.longclearCache()voidcopyCachedData(MemoryRangeReader entityDataCollector)longdataLength()longexportTo(one.microstream.afs.types.AWritableFile file)booleanhasReferences()booleaniterateReferenceIds(one.microstream.persistence.types.PersistenceObjectIdAcceptor referenceIdIterator)longlastTouched()The approximate system time that this particular entity has been last touched.longobjectId()StorageLiveDataFilestorageFile()longstoragePosition()longtypeId()
-
-
-
Method Detail
-
dataLength
long dataLength()
- Returns:
- The entity's data length, meaning the pure content length without any header or meta data.
-
typeId
long typeId()
- Returns:
- The entity's type id.
-
objectId
long objectId()
- Returns:
- The entity's biunique identifying id number.
-
hasReferences
boolean hasReferences()
- Returns:
- The information if this entity's type has reference fields (regardless of a particular entity's actual data).
-
cachedDataLength
long cachedDataLength()
The length this entity occupies in the cache. This might vary, even for fixed length typed, from the values returned bydataLength()as only parts of an entity (e.g. only references) might be loaded into cache and because the cache might hold the header/meta-data of an entity as well.- Returns:
- The length this entity occupies in the cache.
-
lastTouched
long lastTouched()
The approximate system time that this particular entity has been last touched. The returned value is compatible to the value returned bySystem.currentTimeMillis().- Returns:
- approximate system time that this particular entity has been last touched
-
storagePosition
long storagePosition()
-
storageFile
StorageLiveDataFile storageFile()
-
copyCachedData
void copyCachedData(MemoryRangeReader entityDataCollector)
-
clearCache
long clearCache()
-
iterateReferenceIds
boolean iterateReferenceIds(one.microstream.persistence.types.PersistenceObjectIdAcceptor referenceIdIterator)
-
exportTo
long exportTo(one.microstream.afs.types.AWritableFile file)
-
-