NCBI C++ ToolKit
|
Search Toolkit Book for CDbtag
#include <objects/general/Dbtag.hpp>
Public Member Functions | |
CDbtag (void) | |
~CDbtag (void) | |
int | Compare (const CDbtag &dbt2) const |
bool | Match (const CDbtag &dbt2) const |
bool | SetAsMatchingTo (const CDbtag &dbt2) |
void | GetLabel (string *label) const |
bool | IsApproved (EIsRefseq refseq=eIsRefseq_No, EIsSource is_source=eIsSource_No, EIsEstOrGss is_est_or_gss=eIsEstOrGss_No) const |
const char * | IsApprovedNoCase (EIsRefseq refseq=eIsRefseq_No, EIsSource is_source=eIsSource_No) const |
bool | IsApproved (TDbtagGroup group) const |
bool | IsSkippable (void) const |
EDbtagType | GetType (void) const |
bool | GetDBFlags (bool &is_refseq, bool &is_src, string &correct_caps) const |
TDbtagGroup | GetDBFlags (string &correct_caps) const |
void | InvalidateType (void) |
string | GetUrl (void) const |
string | GetUrl (TTaxId taxid) const |
string | GetUrl (const string &taxname) const |
string | GetUrl (const string &genus, const string &species, const string &subspecies=kEmptyStr) const |
![]() | |
CDbtag_Base (void) | |
virtual | ~CDbtag_Base (void) |
DECLARE_INTERNAL_TYPE_INFO () | |
bool | IsSetDb (void) const |
name of database or system Check if a value has been assigned to Db data member. More... | |
bool | CanGetDb (void) const |
Check if it is safe to call GetDb method. More... | |
void | ResetDb (void) |
Reset Db data member. More... | |
const TDb & | GetDb (void) const |
Get the Db member data. More... | |
void | SetDb (const TDb &value) |
Assign a value to Db data member. More... | |
void | SetDb (TDb &&value) |
TDb & | SetDb (void) |
Assign a value to Db data member. More... | |
bool | IsSetTag (void) const |
appropriate tag Check if a value has been assigned to Tag data member. More... | |
bool | CanGetTag (void) const |
Check if it is safe to call GetTag method. More... | |
void | ResetTag (void) |
Reset Tag data member. More... | |
const TTag & | GetTag (void) const |
Get the Tag member data. More... | |
void | SetTag (TTag &value) |
Assign a value to Tag data member. More... | |
TTag & | SetTag (void) |
Assign a value to Tag data member. More... | |
virtual void | Reset (void) |
Reset the whole object. More... | |
![]() | |
CSerialObject (void) | |
virtual | ~CSerialObject (void) |
virtual const CTypeInfo * | GetThisTypeInfo (void) const =0 |
virtual void | Assign (const CSerialObject &source, ESerialRecursionMode how=eRecursive) |
Set object to copy of another one. More... | |
virtual bool | Equals (const CSerialObject &object, ESerialRecursionMode how=eRecursive) const |
Check if both objects contain the same values. More... | |
virtual void | DebugDump (CDebugDumpContext ddc, unsigned int depth) const |
Define method for dumping debug information. More... | |
void | ThrowUnassigned (TMemberIndex index) const |
void | ThrowUnassigned (TMemberIndex index, const char *file_name, int file_line) const |
bool | HasNamespaceName (void) const |
Check if object data type has namespace name. More... | |
const string & | GetNamespaceName (void) const |
Get namespace name. More... | |
bool | HasNamespacePrefix (void) const |
Check if data type has namespace prefix. More... | |
const string & | GetNamespacePrefix (void) const |
Get namespace prefix. More... | |
![]() | |
CObject (void) | |
Constructor. More... | |
CObject (const CObject &src) | |
Copy constructor. More... | |
virtual | ~CObject (void) |
Destructor. More... | |
CObject & | operator= (const CObject &src) THROWS_NONE |
Assignment operator. More... | |
bool | CanBeDeleted (void) const THROWS_NONE |
Check if object can be deleted. More... | |
bool | IsAllocatedInPool (void) const THROWS_NONE |
Check if object is allocated in memory pool (not system heap) More... | |
bool | Referenced (void) const THROWS_NONE |
Check if object is referenced. More... | |
bool | ReferencedOnlyOnce (void) const THROWS_NONE |
Check if object is referenced only once. More... | |
void | AddReference (void) const |
Add reference to object. More... | |
void | RemoveReference (void) const |
Remove reference to object. More... | |
void | ReleaseReference (void) const |
Remove reference without deleting object. More... | |
virtual void | DoNotDeleteThisObject (void) |
Mark this object as not allocated in heap – do not delete this object. More... | |
virtual void | DoDeleteThisObject (void) |
Mark this object as allocated in heap – object can be deleted. More... | |
void * | operator new (size_t size) |
Define new operator for memory allocation. More... | |
void * | operator new[] (size_t size) |
Define new[] operator for 'array' memory allocation. More... | |
void | operator delete (void *ptr) |
Define delete operator for memory deallocation. More... | |
void | operator delete[] (void *ptr) |
Define delete[] operator for memory deallocation. More... | |
void * | operator new (size_t size, void *place) |
Define new operator. More... | |
void | operator delete (void *ptr, void *place) |
Define delete operator. More... | |
void * | operator new (size_t size, CObjectMemoryPool *place) |
Define new operator using memory pool. More... | |
void | operator delete (void *ptr, CObjectMemoryPool *place) |
Define delete operator. More... | |
![]() | |
CDebugDumpable (void) | |
virtual | ~CDebugDumpable (void) |
void | DebugDumpText (ostream &out, const string &bundle, unsigned int depth) const |
void | DebugDumpFormat (CDebugDumpFormatter &ddf, const string &bundle, unsigned int depth) const |
void | DumpToConsole (void) const |
Private Types | |
typedef CDbtag_Base | Tparent |
Private Member Functions | |
CDbtag (const CDbtag &) | |
CDbtag & | operator= (const CDbtag &) |
Static Private Member Functions | |
static bool | x_LooksLikeAccession (const string &tag, int &out_num_alpha, int &out_num_digit, int &out_num_unscr) |
Private Attributes | |
EDbtagType | m_Type |
Additional Inherited Members | |
![]() | |
static void | SetVerifyDataThread (ESerialVerifyData verify) |
static void | SetVerifyDataGlobal (ESerialVerifyData verify) |
static string | UnassignedString (void) |
static CStringUTF8 | UnassignedStringUTF8 (void) |
static char | UnassignedByte (void) |
![]() | |
static NCBI_XNCBI_EXPORT void | ThrowNullPointerException (void) |
Define method to throw null pointer exception. More... | |
static NCBI_XNCBI_EXPORT void | ThrowNullPointerException (const type_info &type) |
static EAllocFillMode | GetAllocFillMode (void) |
static void | SetAllocFillMode (EAllocFillMode mode) |
static void | SetAllocFillMode (const string &value) |
Set mode from configuration parameter value. More... | |
![]() | |
static void | EnableDebugDump (bool on) |
![]() | |
static const char * | ms_UnassignedStr = "<*unassigned*>" |
static const char | ms_UnassignedByte = char(0xcd) |
![]() | |
static const TCount | eCounterBitsCanBeDeleted = 1 << 0 |
Define possible object states. More... | |
static const TCount | eCounterBitsInPlainHeap = 1 << 1 |
Heap signature was found. More... | |
static const TCount | eCounterBitsPlaceMask |
Mask for 'in heap' state flags. More... | |
static const int | eCounterStep = 1 << 2 |
Skip over the "in heap" bits. More... | |
static const TCount | eCounterValid = TCount(1) << (sizeof(TCount) * 8 - 2) |
Minimal value for valid objects (reference counter is zero) Must be a single bit value. More... | |
static const TCount | eCounterStateMask |
Valid object, and object in heap. More... | |
![]() | |
virtual void | DeleteThis (void) |
Virtual method "deleting" this object. More... | |
typedef int CDbtag::TDbtagGroup |
|
private |
enum CDbtag::EDbtagGroup |
enum CDbtag::EDbtagType |
enum CDbtag::EIsEstOrGss |
enum CDbtag::EIsRefseq |
enum CDbtag::EIsSource |
Definition at line 176 of file Dbtag.cpp.
References CObject_id::Compare(), PNocase_Generic< T >::Compare(), CDbtag_Base::GetDb(), and CDbtag_Base::GetTag().
Referenced by CSeq_id::CompareOrdered(), SSortReferenceByName::operator()(), SChildLess::operator()(), s_DbtagCompare(), and s_DbtagEqual().
Definition at line 327 of file Dbtag.cpp.
References fNone, fRefSeq, and fSrc.
Referenced by BOOST_AUTO_TEST_CASE(), CValidator::IsValidDbxref(), and CValidError_imp::ValidateDbxref().
CDbtag::TDbtagGroup CDbtag::GetDBFlags | ( | string & | correct_caps | ) | const |
Definition at line 305 of file Dbtag.cpp.
References CDbtag_Base::CanGetDb(), fNone, and CDbtag_Base::GetDb().
void CDbtag::GetLabel | ( | string * | label | ) | const |
Definition at line 187 of file Dbtag.cpp.
References CObject_id_Base::e_Id, CObject_id_Base::e_Str, NStr::eNocase, CDbtag_Base::GetDb(), GetId(), CDbtag_Base::GetTag(), NStr::IntToString(), label, NStr::StartsWith(), and str().
Referenced by CVariationHandler::GetLabel(), CDiscrepancyObject::GetTextObjectDescription(), GetTextObjectDescription(), CGuiObjectInfoVariant::GetToolTip(), CGeneralIDField::GetVal(), CEditingActionEntireGeneralId::GetValue(), s_GetContentLabel(), CValidError_bioseq::ValidateIDSetAgainstDb(), CGvfWriteRecord::x_AssignAttributeID(), CGvfWriteRecord::x_AssignAttributeParent(), and CXcompareAnnotsApplication::x_ProcessComparison().
CDbtag::EDbtagType CDbtag::GetType | ( | void | ) | const |
Definition at line 289 of file Dbtag.cpp.
References CDbtag_Base::CanGetDb(), eDbtagType_bad, CDbtag_Base::GetDb(), and m_Type.
Referenced by BOOST_AUTO_TEST_CASE(), CSeq_id::Set(), and CVcfWriter::x_WriteFeatureInfo().
string CDbtag::GetUrl | ( | const string & | genus, |
const string & | species, | ||
const string & | subspecies = kEmptyStr |
||
) | const |
string CDbtag::GetUrl | ( | void | ) | const |
Referenced by CFlatXrefQVal::Format().
void CDbtag::InvalidateType | ( | void | ) |
Definition at line 339 of file Dbtag.cpp.
References eDbtagType_bad, and m_Type.
bool CDbtag::IsApproved | ( | EIsRefseq | refseq = eIsRefseq_No , |
EIsSource | is_source = eIsSource_No , |
||
EIsEstOrGss | is_est_or_gss = eIsEstOrGss_No |
||
) | const |
Definition at line 215 of file Dbtag.cpp.
References CDbtag_Base::CanGetDb(), eIsEstOrGss_Yes, eIsRefseq_Yes, eIsSource_Yes, fGenBank, fRefSeq, fSrc, and CDbtag_Base::GetDb().
Referenced by BOOST_AUTO_TEST_CASE(), and CFlatXrefQVal::Format().
bool CDbtag::IsApproved | ( | TDbtagGroup | group | ) | const |
Definition at line 269 of file Dbtag.cpp.
References CDbtag_Base::CanGetDb(), and CDbtag_Base::GetDb().
const char * CDbtag::IsApprovedNoCase | ( | EIsRefseq | refseq = eIsRefseq_No , |
EIsSource | is_source = eIsSource_No |
||
) | const |
Definition at line 245 of file Dbtag.cpp.
References CDbtag_Base::CanGetDb(), eIsRefseq_Yes, eIsSource_Yes, fRefSeq, fSrc, CDbtag_Base::GetDb(), and NULL.
Referenced by BOOST_AUTO_TEST_CASE().
bool CDbtag::IsSkippable | ( | void | ) | const |
Definition at line 281 of file Dbtag.cpp.
References CDbtag_Base::GetDb().
Referenced by CBioseqIndex::CBioseqIndex(), GetProteinId(), GetTitle(), CValidError_imp::Setup(), CEditSeqId::x_CollectChangedIds(), CDeflineGenerator::x_SetFlags(), and CSingleFeatValidator::x_ValidateLocusTagGeneralMatch().
Definition at line 158 of file Dbtag.cpp.
References CSerialObject::Equals(), CDbtag_Base::GetDb(), and CDbtag_Base::GetTag().
Referenced by CDbEquals::operator()(), CValidError_bioseq::ValidateIDSetAgainstDb(), and CFlatXrefQVal::x_XrefInGeneXref().
Definition at line 166 of file Dbtag.cpp.
References CDbtag_Base::GetDb(), CDbtag_Base::GetTag(), CDbtag_Base::SetDb(), and CDbtag_Base::SetTag().
|
staticprivate |
|
mutableprivate |
Definition at line 328 of file Dbtag.hpp.
Referenced by GetType(), and InvalidateType().