NCBI C++ ToolKit
|
Search Toolkit Book for CColumnarVcfCache
#include <gui/widgets/loaders/columnar_vcf_cache.hpp>
Public Member Functions | |
CColumnarVcfCache (const std::string &netcache_key) | |
CColumnarVcfCache (const std::string &url, const std::string &seq_id, const std::string &last_modified) | |
string | GetSeqId () const |
Public Member Functions inherited from CDataCrawlerCache | |
CDataCrawlerCache ()=default | |
Default constructor. More... | |
ECacheState | GetState () const |
Gets the state of the cache object. More... | |
ECacheState | SetState (ECacheState desired_state) |
Changes the state of the cache object. More... | |
size_t | GetReadSize () const |
Returns size of existing BLOB data. More... | |
std::unique_ptr< CNcbiIstream > | GetReadStream () |
Returns stream interface to read BLOB data. More... | |
std::unique_ptr< CNcbiOstream > | GetWriteStream () |
Returns stream interface to write BLOB data. More... | |
void | Remove () |
Removes the cache entry. More... | |
const std::string & | GetKey () const |
Returns the NetCache key of the BLOB. More... | |
const std::string | GetCompoundKey () const |
Returns the compound NetCache key of the BLOB. More... | |
virtual | ~CDataCrawlerCache () |
Destructor. More... | |
Protected Member Functions | |
CDataCrawlerCache overridables | |
virtual CNetICacheClient | x_InitBlobCache () |
Creates the BLOB NetCache instance. More... | |
virtual CNetICacheClient | x_InitSyncCache () |
Creates the sync NetCache instance. More... | |
virtual std::string | x_GetCacheKey () |
Generates the cache key. More... | |
Protected Member Functions inherited from CDataCrawlerCache | |
void | x_Initialize () |
Initializes the cache instances. More... | |
std::string | x_GetCacheKey (ECacheType type) |
Generates the cache key for a given type. More... | |
void | x_StartHeartbeat () |
Starts the heartbeat (thread to keep the sybc object alive) More... | |
void | x_StopHeartbeat () |
Stops the heartbeat (thread to keep the sybc object alive) More... | |
void | x_Heartbeat () |
The heartbeat thread function. More... | |
CNetICacheClient | x_InitICache (const std::string &cache, const std::string &service, const std::string &db) |
Creates a NetCache instance. More... | |
ECacheState | x_ReadState () const |
Reads the state of the sync object. More... | |
void | x_WriteState (ECacheState state, unsigned int ttl=300) |
Writes a new state to the sync object. More... | |
Private Attributes | |
std::string | m_Url |
std::string | m_SeqId |
std::string | m_LastModified |
std::string | m_NCKey |
Additional Inherited Members | |
Public Types inherited from CDataCrawlerCache | |
enum | ECacheState { eState_None , eState_InProgress , eState_NotAccessible , eState_Created } |
Cache object states. More... | |
Protected Types inherited from CDataCrawlerCache | |
enum | ECacheType { eCache_Blob , eCache_Sync } |
Types of cache objects. More... | |
Protected Attributes inherited from CDataCrawlerCache | |
bool | m_isImmutableKey {false} |
do not try to shorten or otherwise modify the root cache key More... | |
Definition at line 45 of file columnar_vcf_cache.hpp.
CColumnarVcfCache::CColumnarVcfCache | ( | const std::string & | netcache_key | ) |
Definition at line 62 of file columnar_vcf_cache.cpp.
References CDataCrawlerCache::m_isImmutableKey, m_NCKey, m_SeqId, and CDataCrawlerCache::x_Initialize().
CColumnarVcfCache::CColumnarVcfCache | ( | const std::string & | url, |
const std::string & | seq_id, | ||
const std::string & | last_modified | ||
) |
|
inline |
Definition at line 50 of file columnar_vcf_cache.hpp.
References m_SeqId.
|
protectedvirtual |
Generates the cache key.
Implements CDataCrawlerCache.
Definition at line 98 of file columnar_vcf_cache.cpp.
References ncbi::grid::netcache::search::fields::key, m_LastModified, m_NCKey, m_SeqId, m_Url, and CVCFVariantsBase::s_GetCurrentVersion().
|
protectedvirtual |
Creates the BLOB NetCache instance.
Implements CDataCrawlerCache.
Definition at line 88 of file columnar_vcf_cache.cpp.
References kVcfCacheBlob, and CDataCrawlerCache::x_InitICache().
|
protectedvirtual |
Creates the sync NetCache instance.
Implements CDataCrawlerCache.
Definition at line 93 of file columnar_vcf_cache.cpp.
References kVcfCacheSync, and CDataCrawlerCache::x_InitICache().
|
private |
Definition at line 63 of file columnar_vcf_cache.hpp.
Referenced by x_GetCacheKey().
|
private |
Definition at line 64 of file columnar_vcf_cache.hpp.
Referenced by CColumnarVcfCache(), and x_GetCacheKey().
|
private |
Definition at line 62 of file columnar_vcf_cache.hpp.
Referenced by CColumnarVcfCache(), GetSeqId(), and x_GetCacheKey().
|
private |
Definition at line 61 of file columnar_vcf_cache.hpp.
Referenced by x_GetCacheKey().