NCBI C++ ToolKit
|
Search Toolkit Book for CAnchoredAln
Query-anchored alignment can be 2 or multi-dimentional. More...
#include <objtools/alnmgr/pairwise_aln.hpp>
Public Types | |
typedef int | TDim |
typedef vector< CRef< CPairwiseAln > > | TPairwiseAlnVector |
Public Types inherited from CObject | |
enum | EAllocFillMode { eAllocFillNone = 1 , eAllocFillZero , eAllocFillPattern } |
Control filling of newly allocated memory. More... | |
typedef CObjectCounterLocker | TLockerType |
Default locker type for CRef. More... | |
typedef atomic< Uint8 > | TCounter |
Counter type is CAtomiCounter. More... | |
typedef Uint8 | TCount |
Alias for value type of counter. More... | |
Public Member Functions | |
CAnchoredAln (void) | |
Default constructor. More... | |
CAnchoredAln (const CAnchoredAln &c) | |
NB: Copy constructor is deep on pairwise_alns so that pairwise_alns can be modified. More... | |
CAnchoredAln & | operator= (const CAnchoredAln &c) |
NB: Assignment operator is deep on pairwise_alns so that pairwise_alns can be modified. More... | |
TDim | GetDim (void) const |
How many rows. More... | |
const TAlnSeqIdIRef & | GetId (TDim row) const |
Seq ids of the rows. More... | |
const TPairwiseAlnVector & | GetPairwiseAlns (void) const |
The vector of pairwise alns. More... | |
TDim | GetAnchorRow (void) const |
Which is the anchor row? More... | |
const TAlnSeqIdIRef & | GetAnchorId (void) const |
What is the seq id of the anchor? More... | |
int | GetScore (void) const |
What is the total score? More... | |
void | SetDim (TDim dim) |
Modify the number of rows. More... | |
TPairwiseAlnVector & | SetPairwiseAlns (void) |
Modify pairwise alns. More... | |
void | SetAnchorRow (TDim anchor_row) |
Modify anchor row (never do this unless you are creating a new alignment and know what you're doing). More... | |
void | SetScore (int score) |
Set the total score. More... | |
int & | SetScore (void) |
Non-const access to the total score. More... | |
bool | SplitStrands (void) |
Split rows with mixed dir into separate rows returns true if the operation was performed. More... | |
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 |
Private Attributes | |
TDim | m_AnchorRow |
TPairwiseAlnVector | m_PairwiseAlns |
int | m_Score |
Static Private Attributes | |
static const TDim | kInvalidAnchorRow = -1 |
Additional Inherited Members | |
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) |
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 CObject | |
virtual void | DeleteThis (void) |
Virtual method "deleting" this object. More... | |
Query-anchored alignment can be 2 or multi-dimentional.
Definition at line 268 of file pairwise_aln.hpp.
typedef int CAnchoredAln::TDim |
Definition at line 272 of file pairwise_aln.hpp.
typedef vector< CRef<CPairwiseAln> > CAnchoredAln::TPairwiseAlnVector |
Definition at line 273 of file pairwise_aln.hpp.
|
inline |
Default constructor.
Definition at line 276 of file pairwise_aln.hpp.
|
inline |
NB: Copy constructor is deep on pairwise_alns so that pairwise_alns can be modified.
Definition at line 284 of file pairwise_aln.hpp.
|
inline |
What is the seq id of the anchor?
Definition at line 337 of file pairwise_aln.hpp.
References GetId(), and m_AnchorRow.
Referenced by x_AdjustAnchorDirection().
|
inline |
Which is the anchor row?
Definition at line 329 of file pairwise_aln.hpp.
References _ASSERT, GetDim(), kInvalidAnchorRow, and m_AnchorRow.
Referenced by BOOST_AUTO_TEST_CASE(), BuildAln(), CreateAnchoredAlnVec(), CreateSplicedsegFromAnchoredAln(), CSparseAln::GetAnchor(), CAlnBuildApp::Run(), CAlnTestApp::Run(), s_TranslateToAlnCoords(), x_AdjustAnchorDirection(), CSparseAln::x_Build(), CAlignCleanup::x_Cleanup_AnchoredAln(), CMergeAlignmentsJob::x_CreateProjectItems(), and CSparse_CI::x_InitIterator().
|
inline |
How many rows.
Definition at line 311 of file pairwise_aln.hpp.
References m_PairwiseAlns.
Referenced by BuildAlignDataSource(), BuildAln(), CAlnSpanVertModel::CAlnSpanVertModel(), CreateAlignSetFromAnchoredAln(), CreateAnchoredAlnVec(), CreateDense_diagFromAnchoredAln(), CreateDensegFromAnchoredAln(), CreatePackedsegFromAnchoredAln(), CreateSeqAlignFromAnchoredAln(), CreateSplicedsegFromAnchoredAln(), GetAnchorRow(), CSparseAln::GetDim(), operator<<(), operator=(), SplitStrands(), x_AdjustAnchorDirection(), CSparseAln::x_Build(), and CTreeBuilderJob::x_CreateProjectItems().
|
inline |
Seq ids of the rows.
Definition at line 317 of file pairwise_aln.hpp.
References GetPairwiseAlns(), and row.
Referenced by BuildAln(), CreateAlignSetFromAnchoredAln(), CreateDense_diagFromAnchoredAln(), CreateDensegFromAnchoredAln(), CreatePackedsegFromAnchoredAln(), and GetAnchorId().
|
inline |
The vector of pairwise alns.
Definition at line 323 of file pairwise_aln.hpp.
References m_PairwiseAlns.
Referenced by BOOST_AUTO_TEST_CASE(), BuildAlignDataSource(), BuildAln(), CreateAlignSetFromAnchoredAln(), CreateAnchoredAlnVec(), CreateDense_diagFromAnchoredAln(), CreateDensegFromAnchoredAln(), CreatePackedsegFromAnchoredAln(), CSparseAln::CreateSegmentIterator(), CreateSplicedsegFromAnchoredAln(), DumpAnchoredAln(), CSparseAln::GetAlignCollection(), CSparseAln::GetAlnPosFromSeqPos(), CSparseAln::GetAlnSeqString(), CSparseAln::GetBaseWidth(), GetId(), CSparseAln::GetSeqAlnStart(), CSparseAln::GetSeqAlnStop(), CSparseAln::GetSeqId(), CSparseAln::GetSeqPosFromAlnPos(), CSparseAln::GetSeqString(), CSparseAln::IsNegativeStrand(), CSparseAln::IsPositiveStrand(), CSparseAln::IsTranslated(), operator<<(), CAlnBuildApp::Run(), x_AdjustAnchorDirection(), CSparseAln::x_Build(), CAlignCleanup::x_Cleanup_AnchoredAln(), CMergeAlignmentsJob::x_CreateProjectItems(), and CSparse_CI::x_InitIterator().
|
inline |
What is the total score?
Definition at line 343 of file pairwise_aln.hpp.
References m_Score.
Referenced by operator<<(), x_AdjustAnchorDirection(), and CSparseAln::x_Build().
|
inline |
NB: Assignment operator is deep on pairwise_alns so that pairwise_alns can be modified.
Definition at line 294 of file pairwise_aln.hpp.
References GetDim(), m_AnchorRow, m_PairwiseAlns, m_Score, and row.
|
inline |
Modify anchor row (never do this unless you are creating a new alignment and know what you're doing).
Setting the anchor row does not update the insertions - they are still aligned to the old anchor.
Definition at line 367 of file pairwise_aln.hpp.
References m_AnchorRow.
Referenced by BuildAln(), CreateAnchoredAlnFromAln(), CreateAnchoredAlnVec(), x_AdjustAnchorDirection(), and CSparseAln::x_Build().
|
inline |
Modify the number of rows.
NB: This resizes the vectors and potentially invalidates the anchor row. Never do this unless you know what you're doing)
Definition at line 351 of file pairwise_aln.hpp.
References _ASSERT, kInvalidAnchorRow, m_AnchorRow, and m_PairwiseAlns.
Referenced by CreateAnchoredAlnFromAln(), CreateAnchoredAlnVec(), x_AdjustAnchorDirection(), and CSparseAln::x_Build().
|
inline |
Modify pairwise alns.
Definition at line 358 of file pairwise_aln.hpp.
References m_PairwiseAlns.
Referenced by BuildAln(), CreateAnchoredAlnFromAln(), CreateAnchoredAlnVec(), s_TranslateToAlnCoords(), x_AdjustAnchorDirection(), and CSparseAln::x_Build().
|
inline |
Set the total score.
Definition at line 373 of file pairwise_aln.hpp.
References m_Score.
Referenced by BuildAlignDataSource(), CreateAnchoredAlnVec(), x_AdjustAnchorDirection(), and CSparseAln::x_Build().
|
inline |
Non-const access to the total score.
Definition at line 379 of file pairwise_aln.hpp.
References m_Score.
bool CAnchoredAln::SplitStrands | ( | void | ) |
Split rows with mixed dir into separate rows returns true if the operation was performed.
Definition at line 235 of file pairwise_aln.cpp.
References _ASSERT, CAlignRangeCollectionList< CAlignRange< TSignedSeqPos > >::fMixedDir, GetDim(), CPairwiseAln::GetFirstId(), CAlignRangeCollectionList< TAlnRange >::GetPolicyFlags(), CPairwiseAln::GetSecondId(), CAlignRangeCollectionList< TAlnRange >::IsSet(), ITERATE, m_AnchorRow, m_PairwiseAlns, CAlignRangeCollectionList< TAlnRange >::push_back(), and row.
Referenced by CAlnBuildApp::Run().
Definition at line 389 of file pairwise_aln.hpp.
Referenced by GetAnchorRow(), and SetDim().
|
private |
Definition at line 390 of file pairwise_aln.hpp.
Referenced by GetAnchorId(), GetAnchorRow(), operator=(), SetAnchorRow(), SetDim(), and SplitStrands().
|
private |
Definition at line 391 of file pairwise_aln.hpp.
Referenced by GetDim(), GetPairwiseAlns(), operator=(), SetDim(), SetPairwiseAlns(), and SplitStrands().
|
private |
Definition at line 392 of file pairwise_aln.hpp.
Referenced by GetScore(), operator=(), and SetScore().