|
CatapultServer
v0.5.0.1 (Elephant)
|
Central cache holding all sub caches. More...
Public Member Functions | |
| CatapultCache (std::vector< std::unique_ptr< SubCachePlugin >> &&subCaches) | |
| Creates a catapult cache around subCaches. More... | |
| ~CatapultCache () | |
| Destroys the cache. More... | |
| CatapultCache (CatapultCache &&) | |
| CatapultCache & | operator= (CatapultCache &&) |
| template<typename TCache > | |
| const TCache & | sub () const |
| Gets a specific sub cache. More... | |
| CatapultCacheView | createView () const |
| Returns a locked cache view based on this cache. More... | |
| CatapultCacheDelta | createDelta () |
| Returns a locked cache delta based on this cache. More... | |
| CatapultCacheDetachableDelta | createDetachableDelta () const |
| void | commit (Height height) |
| Commits all pending changes to the underlying storage and sets the cache height to height. More... | |
| std::vector< std::unique_ptr< const CacheStorage > > | storages () const |
| Gets cache storages for all sub caches. More... | |
| std::vector< std::unique_ptr< CacheStorage > > | storages () |
| Gets cache storages for all sub caches. More... | |
| std::vector< std::unique_ptr< const CacheChangesStorage > > | changesStorages () const |
| Gets cache changes storages for all sub caches. More... | |
Private Attributes | |
| std::unique_ptr< CacheHeight > | m_pCacheHeight |
| std::vector< std::unique_ptr< SubCachePlugin > > | m_subCaches |
Central cache holding all sub caches.
|
explicit |
Creates a catapult cache around subCaches.
|
default |
Destroys the cache.
|
default |
| std::vector< std::unique_ptr< const CacheChangesStorage > > catapult::cache::CatapultCache::changesStorages | ( | ) | const |
Gets cache changes storages for all sub caches.
| void catapult::cache::CatapultCache::commit | ( | Height | height | ) |
Commits all pending changes to the underlying storage and sets the cache height to height.

| CatapultCacheDelta catapult::cache::CatapultCache::createDelta | ( | ) |
Returns a locked cache delta based on this cache.
| CatapultCacheDetachableDelta catapult::cache::CatapultCache::createDetachableDelta | ( | ) | const |
Returns a detachable cache delta based on this cache but without the ability to commit any changes to the original cache.

| CatapultCacheView catapult::cache::CatapultCache::createView | ( | ) | const |
Returns a locked cache view based on this cache.

|
default |
| std::vector< std::unique_ptr< CacheStorage > > catapult::cache::CatapultCache::storages | ( | ) |
Gets cache storages for all sub caches.
| std::vector< std::unique_ptr< const CacheStorage > > catapult::cache::CatapultCache::storages | ( | ) | const |
Gets cache storages for all sub caches.

|
inline |
Gets a specific sub cache.

|
private |
|
private |