NCBI C++ ToolKit
Public Types | Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
CAlignRange< Position > Class Template Reference

Search Toolkit Book for CAlignRange

CAlignRange Represents an element of pairwise alignment of two sequences. More...

#include <util/align_range.hpp>

Public Types

enum  EFlags { fReversed = 0x01 , fFirstRev = 0x02 }
 
typedef Position position_type
 
typedef CAlignRange< Position > TThisType
 
typedef CRange< Position > TRange
 

Public Member Functions

 CAlignRange (void)
 
 CAlignRange (position_type first_from, position_type second_from, position_type len, bool direct=true, bool first_direct=true)
 
bool IsDirect () const
 
bool IsReversed () const
 
bool IsFirstDirect () const
 
bool IsFirstReversed () const
 
position_type GetFirstFrom (void) const
 
position_type GetFirstToOpen (void) const
 
position_type GetFirstTo (void) const
 
position_type GetSecondFrom (void) const
 
position_type GetSecondToOpen (void) const
 
position_type GetSecondTo (void) const
 
TRange GetFirstRange () const
 
TRange GetSecondRange () const
 
bool Empty (void) const
 
bool NotEmpty (void) const
 
position_type GetLength (void) const
 
TThisTypeSetFirstFrom (position_type from)
 
TThisTypeSetSecondFrom (position_type second_from)
 
TThisTypeSetLength (position_type len)
 
TThisTypeSet (position_type first_from, position_type second_from, position_type len)
 
void SetDirect (bool direct=true)
 
void SetReversed (bool reversed=true)
 
void SetFirstDirect (bool direct=true)
 
void SetFirstReversed (bool reversed=true)
 
bool operator== (const TThisType &r) const
 
bool operator!= (const TThisType &r) const
 
position_type GetSecondPosByFirstPos (position_type pos) const
 
position_type GetFirstPosBySecondPos (position_type pos) const
 
bool FirstContains (position_type pos) const
 
bool SecondContains (position_type pos) const
 
TThisType IntersectionWith (const CRange< position_type > &r) const
 Intersection. More...
 
TThisTypeIntersectWith (const CRange< position_type > &r)
 
TThisTypeIntersectSecondWith (const CRange< position_type > &r)
 
bool IntersectingWith (const CRange< position_type > &r) const
 
bool IsAbutting (const TThisType &r) const
 
TThisTypeCombineWithAbutting (const TThisType &r)
 
TThisType CombinationWithAbutting (const TThisType &r) const
 

Static Public Member Functions

static position_type GetEmptyFrom (void)
 
static position_type GetEmptyToOpen (void)
 
static position_type GetEmptyTo (void)
 
static position_type GetEmptyLength (void)
 
static TThisType GetEmpty (void)
 
static position_type GetPositionMin (void)
 
static position_type GetPositionMax (void)
 

Private Attributes

position_type m_FirstFrom
 
position_type m_SecondFrom
 start More...
 
position_type m_Length
 start on the aligned sequence More...
 
int m_Flags
 length of the segment More...
 

Detailed Description

template<class Position>
class CAlignRange< Position >

CAlignRange Represents an element of pairwise alignment of two sequences.

CAlignRange := [from_1, to_open_1), [from_2, to_open_2), direction where: from_1 <= to_open_1, from_2 <= to_open_2 (to_open_1 - from_1) == (to_open_2 - from_2) mapping: if direct from_1 -> from_2, to_1 -> to_2 if reversed from_1 -> to_2, to_1 -> from_2

Definition at line 62 of file align_range.hpp.


The documentation for this class was generated from the following file:
Modified on Fri Apr 26 16:23:38 2024 by modify_doxy.py rev. 669887