fNCKey_SingleServer = 1 << 0,
67fNCKey_NoServerCheck = 1 << 1,
81 voidAssign(
const string& key_str,
85 static boolParseBlobKey(
const char* key_str,
89 bool HasExtensions()
const{
returnm_PrimaryKey.length() < m_Key.length();}
94 stringStripKeyExtensions()
const;
97 static voidAddExtensions(
string& blob_id,
const string& service_name,
98TNCKeyFlags
flags,
unsignedver = 1);
107 static Uint4CalculateChecksum(
const string& host,
unsigned shortport);
114 voidGenerateBlobKey(
string*
key,
119 unsigned intrnd_num,
120time_t creation_time = 0);
122 static stringKeyToCompoundID(
123 const string& key_str,
127 static unsigned intGetBlobId(
const string& key_str);
129 static bool IsValidKey(
const char* key_str,
size_tkey_len,
131{
returnParseBlobKey(key_str, key_len,
NULL, id_pool); }
135{
returnIsValidKey(
key.c_str(),
key.length(), id_pool); }
137 const string& GetKey()
const;
138 unsigned GetId()
const;
139 const string&
GetHost()
const;
140 unsigned short GetPort()
const;
141 unsignedGetHostPortCRC32()
const;
142 unsignedGetVersion()
const;
143time_t GetCreationTime()
const;
144 Uint4GetRandomPart()
const;
145 const string& GetServiceName()
const;
184 inline const string&
190 inline unsigned shortPool of recycled CCompoundID objects.
Declarations of CCompoundIDPool, CCompoundID, and CCompoundIDField.
static bool IsValidKey(const string &key, CCompoundIDPool::TInstance id_pool=NULL)
ENCKeyFlag
Blob and blob key features.
void ClearFlag(ENCKeyFlag flag)
void SetFlag(ENCKeyFlag flag)
unsigned TNCKeyFlags
Binary OR of ENCKeyFlag.
bool GetFlag(ENCKeyFlag flag) const
unsigned GetHostPortCRC32() const
static bool IsValidKey(const char *key_str, size_t key_len, CCompoundIDPool::TInstance id_pool=NULL)
bool HasExtensions() const
CNetCacheKey()
Create an empty object for later use with ParseBlobKey() or Assign().
unsigned short m_Port
TCP/IP port number.
unsigned short GetPort() const
Uint4 GetRandomPart() const
const string & GetKey() const
unsigned m_HostPortCRC32
CRC32 checksum of the host:port combination.
unsigned m_Version
Key version.
string m_Host
server name
unsigned GetVersion() const
TNCKeyFlags GetFlags() const
const string & GetHost() const
time_t GetCreationTime() const
const string & GetServiceName() const
string StripKeyExtensions() const
If the blob key has been parsed successfully, this method returns a trimmed "base" version of the key...
unsigned int m_Id
BLOB id.
const CSeq_id & GetId(const CSeq_loc &loc, CScope *scope)
If all CSeq_ids embedded in CSeq_loc refer to the same CBioseq, returns the first CSeq_id found,...
uint32_t Uint4
4-byte (32-bit) unsigned integer
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
unsigned short GetPort() const
Get the listening port number back.
#define NCBI_XCONNECT_EXPORT
Uint4 GetHost(TEndpointKey key)
const struct ncbi::grid::netcache::search::fields::KEY key
The NCBI C++/STL use hints.
Defines Limits for the types used in NCBI C/C++ toolkit.
Meaningful information encoded in the NetCache key.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4