NCBI C++ ToolKit
|
Search Toolkit Book for CSeq_loc_Mapper
#include <objmgr/seq_loc_mapper.hpp>
Public Types | |
enum | ESeqMapDirection { eSeqMap_Up , eSeqMap_Down } |
enum | EGCAssemblyAlias { eGCA_Genbank , eGCA_GenbankAcc , eGCA_Refseq , eGCA_RefseqAcc , eGCA_UCSC , eGCA_Other } |
Destination of seq-id mapping through a GC-Assembly. More... | |
enum | EScopeFlag { eOriginalScope , eCopyScope } |
Using CScope for virtual bioseqs created from GC-Assemblies. More... | |
Public Types inherited from CSeq_loc_Mapper_Base | |
enum | EFeatMapDirection { eLocationToProduct , eProductToLocation } |
Mapping direction used when initializing the mapper with a feature. More... | |
enum | EMapOptions { fAlign_Dense_seg_TotalRange = 1 << 0 , fAlign_Sparse_ToFirst = 0 , fAlign_Sparse_ToSecond = 1 << 1 , fMapSingleLevel = 1 << 2 , fTrimMappedLocation = 1 << 3 } |
Options for interpretations of locations. More... | |
enum | ESplicedRow { eSplicedRow_Prod = 0 , eSplicedRow_Gen = 1 } |
Spliced-seg row indexing constants. More... | |
enum | FFuzzOption { fFuzzOption_CStyle = 1 << 0 , fFuzzOption_RemoveLimTlOrTr = 1 << 1 } |
enum | FAnnotMapFlag { fAnnotMap_Location = 1 << 0 , fAnnotMap_Product = 1 << 1 , fAnnotMap_Both = fAnnotMap_Location | fAnnotMap_Product , fAnnotMap_RemoveNonMapping = 1 << 2 , fAnnotMap_ThrowOnFailure = 1 << 3 , fAnnotMap_Default = fAnnotMap_Both } |
Flags defining seq-annot mapping options. More... | |
enum | EMapResult { eMapped_None = 0 , eMapped_Some , eMapped_All } |
Result of seq-annot mapping. More... | |
enum | ESeqType { eSeq_unknown = 0 , eSeq_nuc = 1 , eSeq_prot = 3 } |
typedef int | TMapOptions |
typedef int | TFuzzOption |
typedef int | TAnnotMapFlags |
typedef set< CSeq_id_Handle > | TSynonyms |
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 | |
CSeq_loc_Mapper (CMappingRanges *mapping_ranges, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a pre-filled CMappipngRanges. More... | |
CSeq_loc_Mapper (const CSeq_feat &map_feat, EFeatMapDirection dir, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a feature, both location and product must be set. More... | |
CSeq_loc_Mapper (const CSeq_loc &source, const CSeq_loc &target, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping between two seq_locs. More... | |
CSeq_loc_Mapper (const CSeq_align &map_align, const CSeq_id &to_id, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment. More... | |
CSeq_loc_Mapper (const CSeq_align &map_align, size_t to_row, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
CSeq_loc_Mapper (const CSeq_id &from_id, const CSeq_id &to_id, const CSeq_align &map_align, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment using specific source and target ids. More... | |
CSeq_loc_Mapper (size_t from_row, size_t to_row, const CSeq_align &map_align, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment using specific source and target row numbers. More... | |
CSeq_loc_Mapper (CBioseq_Handle target_seq, ESeqMapDirection direction, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping between segments and the top level sequence. More... | |
CSeq_loc_Mapper (CBioseq_Handle target_seq, ESeqMapDirection direction, SSeqMapSelector selector, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping between segments and the top level sequence. More... | |
CSeq_loc_Mapper (const CSeqMap &seq_map, ESeqMapDirection direction, const CSeq_id *top_level_id=0, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a seq-map. More... | |
CSeq_loc_Mapper (const CSeqMap &seq_map, ESeqMapDirection direction, SSeqMapSelector selector, const CSeq_id *top_level_id=0, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a seq-map. More... | |
CSeq_loc_Mapper (size_t depth, const CBioseq_Handle &top_level_seq, ESeqMapDirection direction, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping between segments and the top level sequence limited by depth. More... | |
CSeq_loc_Mapper (size_t depth, const CSeqMap &top_level_seq, ESeqMapDirection direction, const CSeq_id *top_level_id=0, CScope *scope=0, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Depth-limited mapping through a seq-map. More... | |
CSeq_loc_Mapper (const CGC_Assembly &gc_assembly, EGCAssemblyAlias to_alias, CScope *scope=0, EScopeFlag scope_flag=eCopyScope) | |
Initialize the mapper to map through a GC-Assembly to the selected alias type. More... | |
CSeq_loc_Mapper (const CGC_Assembly &gc_assembly, ESeqMapDirection direction, SSeqMapSelector selector, CScope *scope=0, EScopeFlag scope_flag=eCopyScope, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Initialize the mapper to map through deltas from a GC-Assembly. More... | |
~CSeq_loc_Mapper (void) | |
Public Member Functions inherited from CSeq_loc_Mapper_Base | |
CSeq_loc_Mapper_Base (CMappingRanges *mapping_ranges, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a pre-filled CMappipngRanges. More... | |
CSeq_loc_Mapper_Base (const CSeq_feat &map_feat, EFeatMapDirection dir, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through a feature, both location and product must be set. More... | |
CSeq_loc_Mapper_Base (const CSeq_loc &source, const CSeq_loc &target, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping between two seq_locs. More... | |
CSeq_loc_Mapper_Base (const CSeq_align &map_align, const CSeq_id &to_id, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment. More... | |
CSeq_loc_Mapper_Base (const CSeq_id &from_id, const CSeq_id &to_id, const CSeq_align &map_align, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment using specific source and target ids. More... | |
CSeq_loc_Mapper_Base (const CSeq_align &map_align, const CSeq_id &to_id, TMapOptions opts, IMapper_Sequence_Info *seq_info) | |
CSeq_loc_Mapper_Base (const CSeq_align &map_align, size_t to_row, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Sparse alignments require special row indexing since each row contains two seq-ids. More... | |
CSeq_loc_Mapper_Base (size_t from_row, size_t to_row, const CSeq_align &map_align, CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
Mapping through an alignment using specific source and target row numbers. More... | |
CSeq_loc_Mapper_Base (const CSeq_align &map_align, size_t to_row, TMapOptions opts, IMapper_Sequence_Info *seq_info) | |
~CSeq_loc_Mapper_Base (void) | |
void | SetFuzzOption (TFuzzOption newOption) |
CSeq_loc_Mapper_Base & | SetMergeNone (void) |
Intervals' merging mode MergeNone and MergeAbutting do not change the order of ranges in the destination seq-loc. More... | |
CSeq_loc_Mapper_Base & | SetMergeAbutting (void) |
Merge only abutting intervals, keep overlapping. More... | |
CSeq_loc_Mapper_Base & | SetMergeBySeg (void) |
Merge only intervals from the same group. More... | |
CSeq_loc_Mapper_Base & | SetMergeContained (void) |
Merge intervals only if one is completely covered by another. More... | |
CSeq_loc_Mapper_Base & | SetMergeAll (void) |
Merge any abutting or overlapping intervals. More... | |
CSeq_loc_Mapper_Base & | SetGapPreserve (void) |
Whether to preserve or remove NULL sub-locations (usually indicating gaps) from the result. More... | |
CSeq_loc_Mapper_Base & | SetGapRemove (void) |
CSeq_loc_Mapper_Base & | SetTrimSplicedSeg (bool trim) |
For mapping spliced-segs only: preserve or trim starting/ending indels. More... | |
CSeq_loc_Mapper_Base & | KeepNonmappingRanges (void) |
Keep ranges which can not be mapped. More... | |
CSeq_loc_Mapper_Base & | TruncateNonmappingRanges (void) |
CSeq_loc_Mapper_Base & | SetCheckStrand (bool value=true) |
Check strands before mapping a range. More... | |
CSeq_loc_Mapper_Base & | MixedAlignsAsSpliced (bool value=true) |
When set to 'true' if mapped alignment has exactly one genomic and one protein row, convert it to spliced-seg. More... | |
CSeq_loc_Mapper_Base & | IncludeSourceLocs (bool value=true) |
Include source ranges in the mapped location. More... | |
CSeq_loc_Mapper_Base & | SetErrorOnPartial (bool value=true) |
Report source range trimming as an error. More... | |
CRef< CSeq_loc > | Map (const CSeq_loc &src_loc) |
Map seq-loc. More... | |
CRef< CSeq_loc > | MapTotalRange (const CSeq_loc &seq_loc) |
Take the total range from the location and run it through the mapper. More... | |
CRef< CSeq_align > | Map (const CSeq_align &src_align) |
Map the whole alignment. More... | |
CRef< CSeq_align > | Map (const CSeq_align &src_align, size_t row) |
Map a single row of the alignment. More... | |
CRef< CSeq_graph > | Map (const CSeq_graph &src_graph) |
Map seq-graph. More... | |
EMapResult | Map (CSeq_annot &annot, TAnnotMapFlags flags=fAnnotMap_Default) |
Map each object from the Seq-annot and replace the original with the mapped one. More... | |
bool | LastIsPartial (void) |
Check if the last mapping resulted in partial location (not all ranges from the original location could be mapped to the target). More... | |
const CSeq_id_Handle & | CollectSynonyms (const CSeq_id_Handle &id) const |
CSeq_loc_Mapper_Base (CSeq_loc_Mapper_Options options=CSeq_loc_Mapper_Options()) | |
ESeqType | GetSeqTypeById (const CSeq_id_Handle &idh) const |
Methods for getting sequence types, use cached types (m_SeqTypes) if possible. More... | |
ESeqType | GetSeqTypeById (const CSeq_id &id) const |
void | SetSeqTypeById (const CSeq_id_Handle &idh, ESeqType seqtype) const |
Methods for setting sequence types. More... | |
void | SetSeqTypeById (const CSeq_id &id, ESeqType seqtype) const |
int | GetWidthById (const CSeq_id_Handle &idh) const |
Get sequence width. More... | |
int | GetWidthById (const CSeq_id &id) const |
const CMappingRanges & | GetMappingRanges (void) const |
Get mapping ranges. More... | |
void | CollectSynonyms (const CSeq_id_Handle &id, TSynonyms &synonyms) const |
NOTE: In most cases CollectSynonyms(const CSeq_id_Handle& id) should be used instead, since it takes care of synonym storage and mapping. 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 |
Protected Member Functions | |
virtual CSeq_align_Mapper_Base * | InitAlignMapper (const CSeq_align &src_align) |
Protected Member Functions inherited from CSeq_loc_Mapper_Base | |
ESeqType | GetSeqType (const CSeq_id_Handle &idh) const |
TSeqPos | GetSequenceLength (const CSeq_id &id) |
void | x_InitializeFeat (const CSeq_feat &map_feat, EFeatMapDirection dir) |
void | x_InitializeLocs (const CSeq_loc &source, const CSeq_loc &target, int src_frame=0, int dst_frame=0) |
void | x_InitializeAlign (const CSeq_align &map_align, const CSeq_id &to_id, const CSeq_id *from_id=nullptr) |
void | x_InitializeAlign (const CSeq_align &map_align, const TSynonyms &to_ids, const TSynonyms *from_ids=nullptr) |
void | x_InitializeAlign (const CSeq_align &map_align, size_t to_row, size_t from_row=size_t(-1)) |
void | x_PreserveDestinationLocs (void) |
void | x_NextMappingRange (const CSeq_id &src_id, TSeqPos &src_start, TSeqPos &src_len, ENa_strand src_strand, const CSeq_id &dst_id, TSeqPos &dst_start, TSeqPos &dst_len, ENa_strand dst_strand, const CInt_fuzz *fuzz_from=0, const CInt_fuzz *fuzz_to=0, int frame=0, TSeqPos src_bioseq_len=kInvalidSeqPos) |
void | x_AddConversion (const CSeq_id &src_id, TSeqPos src_start, ENa_strand src_strand, const CSeq_id &dst_id, TSeqPos dst_start, ENa_strand dst_strand, TSeqPos length, bool ext_right, int frame, TSeqPos src_bioseq_len, TSeqPos dst_length) |
void | x_MapSeq_loc (const CSeq_loc &src_loc) |
void | x_PushRangesToDstMix (void) |
Protected Member Functions inherited from CObject | |
virtual void | DeleteThis (void) |
Virtual method "deleting" this object. More... | |
Private Attributes | |
CHeapScope | m_Scope |
Mapping locations and alignments between bioseqs through seq-locs, features, alignments or between parts of segmented bioseqs.
Definition at line 75 of file seq_loc_mapper.hpp.