NCBI C++ ToolKit
|
Search Toolkit Book for CLocusItem
#include <objtools/format/items/locus_item.hpp>
Public Member Functions | |
CLocusItem (CBioseqContext &ctx) | |
void | Format (IFormatter &formatter, IFlatTextOStream &text_os) const override |
const string & | GetName (void) const |
const string & | GetFullName (void) const |
size_t | GetLength (void) const |
TStrand | GetStrand (void) const |
TBiomol | GetBiomol (void) const |
TTopology | GetTopology (void) const |
const string & | GetDivision (void) const |
const string & | GetDate (void) const |
EItem | GetItemType () const override |
Public Member Functions inherited from CFlatItem | |
bool | IsSetObject (void) const |
const CSerialObject * | GetObject (void) const |
CBioseqContext * | GetContext (void) |
CBioseqContext * | GetContext (void) const |
bool | Skip (void) const |
bool | IsExternal (void) const |
~CFlatItem (void) | |
Public Member Functions inherited from IFlatItem | |
virtual | ~IFlatItem (void) |
Public Member Functions inherited from CObject | |
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... | |
virtual void | DebugDump (CDebugDumpContext ddc, unsigned int depth) const |
Define method for dumping debug information. More... | |
Public Member Functions inherited from CDebugDumpable | |
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 |
Static Public Member Functions | |
static string | GetDivision (const CBioseq_Handle &bsh, const CBioseqContext *ctx=0) |
Static Public Member Functions inherited from CObject | |
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 Public Member Functions inherited from CDebugDumpable | |
static void | EnableDebugDump (bool on) |
Private Member Functions | |
void | x_GatherInfo (CBioseqContext &ctx) override |
void | x_SetName (CBioseqContext &ctx) |
void | x_SetLength (CBioseqContext &ctx) |
void | x_SetStrand (CBioseqContext &ctx) |
void | x_SetBiomol (CBioseqContext &ctx) |
void | x_SetTopology (CBioseqContext &ctx) |
void | x_SetDivision (CBioseqContext &ctx) |
void | x_SetDate (CBioseqContext &ctx) |
const CDate * | x_GetDateForBioseq (const CBioseq_Handle &bsh) const |
const CDate * | x_GetLaterDate (const CDate *d1, const CDate *d2) const |
bool | x_NameHasBadChars (const string &name) const |
Private Attributes | |
string | m_Name |
string | m_FullName |
size_t | m_Length |
TStrand | m_Strand |
TBiomol | m_Biomol |
TTopology | m_Topology |
string | m_Division |
string | m_Date |
Additional Inherited Members | |
Static Public Attributes inherited from CObject | |
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... | |
Protected Member Functions inherited from CFlatItem | |
CFlatItem (CBioseqContext *ctx=0) | |
void | x_SetObject (const CSerialObject &obj) |
void | x_SetContext (CBioseqContext &ctx) |
void | x_SetSkip (void) |
void | x_SetExternal (void) |
Protected Member Functions inherited from CObject | |
virtual void | DeleteThis (void) |
Virtual method "deleting" this object. More... | |
Definition at line 57 of file locus_item.hpp.
typedef CMolInfo::TBiomol CLocusItem::TBiomol |
Definition at line 60 of file locus_item.hpp.
Definition at line 61 of file locus_item.hpp.
Definition at line 62 of file locus_item.hpp.
CLocusItem::CLocusItem | ( | CBioseqContext & | ctx | ) |
Definition at line 74 of file locus_item.cpp.
References ctx.
|
overridevirtual |
Implements CFlatItem.
Definition at line 86 of file locus_item.cpp.
References IFormatter::FormatLocus().
|
inline |
Definition at line 141 of file locus_item.hpp.
References m_Biomol.
Referenced by CEmblFormatter::FormatLocus(), CGBSeqFormatter::FormatLocus(), and CGenbankFormatter::FormatLocus().
Definition at line 162 of file locus_item.hpp.
References m_Date.
Referenced by CGenbankFormatter::FormatLocus().
|
static |
Definition at line 793 of file locus_item.cpp.
References ctx, CSeqdesc_Base::e_Molinfo, CSeq_inst_Base::eRepr_delta, CMolInfo_Base::eTech_unknown, CDelta_ext_Base::Get(), CSeq_ext_Base::GetDelta(), CBioseq_Handle::GetInst_Ext(), CBioseq_Handle::GetInst_Repr(), CBioseq_Handle::IsAa(), CSeq_ext_Base::IsDelta(), CBioseq_Handle::IsSetInst_Ext(), CBioseq_Handle::IsSetInst_Repr(), ITERATE, x_GetDivisionProc(), and x_GetDivisionProcIdx().
Definition at line 155 of file locus_item.hpp.
References m_Division.
Referenced by CEmblFormatter::FormatLocus(), CGBSeqFormatter::FormatLocus(), and CGenbankFormatter::FormatLocus().
Definition at line 120 of file locus_item.hpp.
References m_FullName.
Referenced by CFlatFileSequenceListJob::CFlatFileSeqBuilder::AddItem(), CFlatFileLocusItem::CalcSize(), and CGenbankFormatter::FormatLocus().
|
overridevirtual |
Implements IFlatItem.
Definition at line 81 of file locus_item.cpp.
References IFlatItem::eItem_Locus.
|
inline |
Definition at line 127 of file locus_item.hpp.
References m_Length.
Referenced by CEmblFormatter::FormatLocus(), CGBSeqFormatter::FormatLocus(), and CGenbankFormatter::FormatLocus().
Definition at line 113 of file locus_item.hpp.
References m_Name.
Referenced by CFlatFileFactoryBuilder::AddItem(), CEmblFormatter::FormatLocus(), CGBSeqFormatter::FormatLocus(), CGenbankFormatter::FormatLocus(), and s_GetFirstBioseqName().
|
inline |
Definition at line 134 of file locus_item.hpp.
References m_Strand.
Referenced by CGBSeqFormatter::FormatLocus(), and CGenbankFormatter::FormatLocus().
|
inline |
Definition at line 148 of file locus_item.hpp.
References m_Topology.
Referenced by CEmblFormatter::FormatLocus(), CGBSeqFormatter::FormatLocus(), and CGenbankFormatter::FormatLocus().
|
overrideprivatevirtual |
Reimplemented from CFlatItem.
Definition at line 105 of file locus_item.cpp.
References ctx, CSeqdesc_Base::e_Molinfo, CSeqdesc_Base::GetMolinfo(), x_SetBiomol(), x_SetDate(), x_SetDivision(), x_SetLength(), x_SetName(), CFlatItem::x_SetObject(), x_SetStrand(), and x_SetTopology().
|
private |
Definition at line 895 of file locus_item.cpp.
References CSP_block_Base::CanGetAnnotupd(), CSP_block_Base::CanGetCreated(), CEMBL_block_Base::CanGetCreation_date(), CPDB_replace_Base::CanGetDate(), CPDB_block_Base::CanGetDeposition(), CGB_block_Base::CanGetEntry_date(), CPDB_block_Base::CanGetReplace(), CSP_block_Base::CanGetSequpd(), CEMBL_block_Base::CanGetUpdate_date(), CSeqdesc_Base::e_Create_date, CSeqdesc_Base::e_Embl, CSeqdesc_Base::e_Genbank, CSeqdesc_Base::e_Pdb, CSeqdesc_Base::e_Sp, CSeqdesc_Base::e_Update_date, CSP_block_Base::GetAnnotupd(), CSeqdesc_Base::GetCreate_date(), CSP_block_Base::GetCreated(), CEMBL_block_Base::GetCreation_date(), CPDB_replace_Base::GetDate(), CPDB_block_Base::GetDeposition(), CSeqdesc_Base::GetEmbl(), CGB_block_Base::GetEntry_date(), CSeqdesc_Base::GetGenbank(), CSeqdesc_Base::GetPdb(), CPDB_block_Base::GetReplace(), CSP_block_Base::GetSequpd(), CSeqdesc_Base::GetSp(), CSeqdesc_Base::GetUpdate_date(), CEMBL_block_Base::GetUpdate_date(), CDate_Base::IsStd(), result, and x_GetLaterDate().
Referenced by x_SetDate().
Definition at line 973 of file locus_item.cpp.
References CDate::Compare(), CDate_Base::e_Str, CDate::eCompare_after, and CDate_Base::Which().
Referenced by x_GetDateForBioseq().
Definition at line 327 of file locus_item.cpp.
References isalnum(), and ITERATE.
Referenced by x_SetName().
|
private |
Definition at line 385 of file locus_item.cpp.
References ctx, CMolInfo_Base::eBiomol_genomic, CMolInfo_Base::eBiomol_other_genetic, CMolInfo_Base::eBiomol_peptide, CMolInfo_Base::eBiomol_pre_RNA, CMolInfo_Base::eBiomol_tmRNA, CMolInfo_Base::eBiomol_unknown, CSeq_inst_Base::eMol_aa, CSeq_inst_Base::eMol_na, CSeq_inst_Base::eMol_not_set, CSeq_inst_Base::eMol_rna, CMolInfo_Base::GetBiomol(), CFlatItem::GetObject(), and m_Biomol.
Referenced by x_GatherInfo().
|
private |
Definition at line 874 of file locus_item.cpp.
References ctx, DateToString(), GetNucleotideParent(), m_Date, and x_GetDateForBioseq().
Referenced by x_GatherInfo().
|
private |
Definition at line 828 of file locus_item.cpp.
References CEMBL_block_Base::CanGetDiv(), ctx, CSeqdesc_Base::e_Embl, CEMBL_block_Base::eDiv_other, CEMBL_block_Base::GetDiv(), CFlatItem::GetObject(), m_Division, s_IsGenomeView(), x_GetDivisionProc(), and x_GetDivisionProcIdx().
Referenced by x_GatherInfo().
|
private |
Definition at line 341 of file locus_item.cpp.
References ctx, GetLength(), and m_Length.
Referenced by x_GatherInfo().
|
private |
Definition at line 244 of file locus_item.cpp.
References basename, ctx, eGetId_Best, CTextseq_id_Base::GetAccession(), GetId(), CTextseq_id_Base::GetName(), NStr::IsBlank(), CTextseq_id_Base::IsSetAccession(), CTextseq_id_Base::IsSetName(), m_FullName, m_Name, s_AddLocusSuffix(), s_FastaGetOriginalID(), s_IsGenomeView(), s_ShouldUseOriginalID(), and x_NameHasBadChars().
Referenced by x_GatherInfo().
|
private |
Definition at line 349 of file locus_item.cpp.
References ctx, CMolInfo_Base::eBiomol_cRNA, CMolInfo_Base::eBiomol_mRNA, CMolInfo_Base::eBiomol_peptide, CMolInfo_Base::eBiomol_tmRNA, CSeq_inst_Base::eMol_dna, CSeq_inst_Base::eMol_not_set, CSeq_inst_Base::eMol_rna, CSeq_inst_Base::eStrand_ds, CSeq_inst_Base::eStrand_not_set, CSeq_inst_Base::eStrand_other, CSeq_inst_Base::eStrand_ss, CBioseq_Handle::GetInst_Mol(), CBioseq_Handle::GetInst_Strand(), CBioseq_Handle::IsSetInst_Mol(), CBioseq_Handle::IsSetInst_Strand(), m_Biomol, and m_Strand.
Referenced by x_GatherInfo().
|
private |
Definition at line 422 of file locus_item.cpp.
References CSeq_interval_Base::CanGetStrand(), ctx, eNa_strand_minus, CSeq_inst_Base::eTopology_circular, CSeq_inst_Base::eTopology_linear, CBioseq_Handle::GetBioseqLength(), CSeq_interval_Base::GetFrom(), CBioseq_Handle::GetInst_Topology(), CSeq_loc_Base::GetInt(), CSeq_interval_Base::GetStrand(), CSeq_interval_Base::GetTo(), CSeq_loc_Base::IsInt(), CBioseq_Handle::IsSetInst_Length(), CSeq_loc_Base::IsWhole(), and m_Topology.
Referenced by x_GatherInfo().
|
private |
Definition at line 101 of file locus_item.hpp.
Referenced by GetBiomol(), x_SetBiomol(), and x_SetStrand().
|
private |
Definition at line 104 of file locus_item.hpp.
Referenced by GetDate(), and x_SetDate().
|
private |
Definition at line 103 of file locus_item.hpp.
Referenced by GetDivision(), and x_SetDivision().
|
private |
Definition at line 98 of file locus_item.hpp.
Referenced by GetFullName(), and x_SetName().
|
private |
Definition at line 99 of file locus_item.hpp.
Referenced by GetLength(), and x_SetLength().
|
private |
Definition at line 97 of file locus_item.hpp.
Referenced by GetName(), and x_SetName().
|
private |
Definition at line 100 of file locus_item.hpp.
Referenced by GetStrand(), and x_SetStrand().
|
private |
Definition at line 102 of file locus_item.hpp.
Referenced by GetTopology(), and x_SetTopology().