80 template<
typename Key,
typename Data,
typename Compare = less<Key>,
typename Alloc = allocator<pair<const Key,Data> > >
81 class CMapWithOriginalOrderingIteration :
private map<Key, Data, Compare, Alloc>
104 m_keysInOriginalOrder.push_back( x.first );
112 iterator find_iter =
find(k);
113 if( find_iter !=
end() ) {
115 return find_iter->second;
122 return result.first->second;
125 typedef vector<Key> TKeyVec;
126 const TKeyVec & GetKeysInOriginalOrder(
void)
const {
128 return m_keysInOriginalOrder;
132 TKeyVec m_keysInOriginalOrder;
135 constexpr
auto ConstructSortMap()
164 std::array<unsigned char, CSeqdesc::E_ChoiceStopper::e_MaxChoice> _sorted{};
165 static_assert(init_seqdesc_sortmap.size() <= _sorted.size());
166 for (
auto& it: _sorted)
169 unsigned char index=0;
170 for (
auto rec: init_seqdesc_sortmap)
172 _sorted[rec] = index;
179 auto seqdesc_sortmap = ConstructSortMap();
181 struct CompareSeqdesc
185 if (c<0 || c>=seqdesc_sortmap.size())
187 return seqdesc_sortmap[c];
192 return mapit(l->
Which()) < mapit(
r->Which());
210 if ((*it)->IsLiteral()) {
211 len = (*it)->GetLiteral().GetLength();
212 }
else if ((*it)->IsLoc()) {
227 if (
delta->IsLoc())
return false;
228 if (
delta->GetLiteral().CanGetSeq_data() &&
delta->GetLiteral().GetSeq_data().IsGap()){
236 if (!seq_hl)
return false;
239 if (!start)
return false;
244 if (
i < (start - 1) )
continue;
245 if (it.IsInGap())
return true;
252 if (!seq_hl)
return false;
257 if (stop >= seq_vec.
size() - 1)
return false;
260 if (
i < (stop + 1) )
continue;
261 if (it.IsInGap())
return true;
276 if ( it->IsSeq() && it->GetSeq().GetInst_Mol() != seq_mol ) {
278 "Unable to add part due to conflicting molecular types");
307 back_inserter(segs));
325 parts = it->SetSet();
326 }
else if ( it->IsSeq() &&
328 master = it->SetSeq();
332 if ( !parts || !master ) {
348 if ( !target || !insert ) {
354 }
else if ( target.
IsSet() && insert.
IsSeq() ) {
371 prot.MoveTo(nuc_prot);
377 static size_t count = 0;
402 seq->
SetId().push_back(
id);
428 }
else if ( to_mol == add_mol ) {
471 if ( !
set || !seq ) {
477 if ( !seq_edit || !set_edit ) {
520 seq_edit.
MoveTo(set_edit);
528 for (
auto it:
set.Get()) {
529 if (it->Equals(desc)) {
531 }
else if (it->IsPub() &&
533 it->GetPub().GetPub().SameCitation(desc.
GetPub().
GetPub())) {
545 seq_descr.
Set().push_back(d);
571 }
else if (entry.
IsSet()) {
616 if (entry->
IsSeq()) {
630 if( ! direct_child_ci ) {
635 if( direct_child_ci ) {
642 for( ; annot_ci; ++annot_ci ) {
655 typedef vector<CSeq_entry_EditHandle> TBioseqSetsToPromote;
656 TBioseqSetsToPromote bioseqSetsToPromote;
660 for( ; direct_child_set_ci; ++direct_child_set_ci ) {
671 ++direct_child_direct_child_ci;
672 _ASSERT( ! direct_child_direct_child_ci );
679 desc_choices_to_erase );
687 bioseqSetsToPromote.push_back(
688 direct_child_direct_child_eh );
693 ITERATE( TBioseqSetsToPromote, promoted_set_it, bioseqSetsToPromote ) {
695 promoted_set_it->GetParentEntry().Remove();
718 }
else if ( rhs.
IsNull() ) {
728 return lhs_asn < rhs_asn;
739 if( asn_text.empty() ) {
741 stringstream asn_strm;
743 asn_strm.str().swap( asn_text );
762 if( ! target || ! target.
IsSet() ) {
776 bool child_became_parent =
false;
777 if( ! target_parent_h ) {
780 target_parent_h = bioseq_set_h;
781 child_became_parent =
true;
794 typedef vector< CConstRef<CSeqdesc> > TDescRefVec;
795 TDescRefVec vecDescsToAddToNewBioseqSet;
797 typedef vector< CConstRef<CSeq_annot> > TAnnotRefVec;
798 TAnnotRefVec vecAnnotsToAddToNewBioseqSet;
809 if( best_entry_for_bioseq &&
813 if( parent_entry && parent_entry.
IsSet() &&
817 best_entry_for_bioseq = parent_entry;
820 if( ! best_entry_for_bioseq ) {
841 for( ; desc_ci; ++desc_ci ) {
842 vecDescsToAddToNewBioseqSet.push_back(
847 for( ; annot_ci; ++annot_ci ) {
861 for( ; dest_desc_ci; ++dest_desc_ci ) {
865 ITERATE( TDescRefVec, src_seqdesc_ref_it, vecDescsToAddToNewBioseqSet ) {
866 if( descsSeen.
find(*src_seqdesc_ref_it) != descsSeen.
end() ) {
873 descsSeen.
insert( *src_seqdesc_ref_it );
882 for( ; dest_annot_ci; ++dest_annot_ci ) {
886 ITERATE( TAnnotRefVec, src_annot_it, vecAnnotsToAddToNewBioseqSet ) {
887 if( annotsSeen.
find(*src_annot_it) != annotsSeen.
end() ) {
894 annotsSeen.
insert( *src_annot_it );
899 if( child_became_parent ) {
903 vector<CSeq_entry_Handle> siblingVec;
908 ++new_set_sibling_ci;
910 for( ; new_set_sibling_ci; ++new_set_sibling_ci ) {
911 siblingVec.push_back(*new_set_sibling_ci);
915 bool bNeedsNewSet =
false;
916 ITERATE( vector<CSeq_entry_Handle>, sibling_it, siblingVec ) {
917 if( sibling_it->IsSeq() ) {
922 if( sibling_it->IsSet() &&
937 ITERATE( vector<CSeq_entry_Handle>, sibling_it, siblingVec ) {
949 for( ; parent_descr_ci; ++parent_descr_ci ) {
967 if( ! target || ! target.
IsSet() ) {
981 for( ; direct_child_ci; ++direct_child_ci ) {
982 vecOfSeqEntryHandles.push_back(*direct_child_ci);
1005 bool bAnyAlignChanged =
false;
1012 typedef vector< CConstRef<CDense_diag> > TDenseDiagVec;
1016 TMapEntryToDenseDiags mapEntryToDenseDiags;
1023 pDendiag->IsSetIds() && pDendiag->GetIds().size() == 2 )
1030 bool bRemoveDendiag =
false;
1039 mapDescendentToInputEntry.
find(bioseqs_entry) :
1040 mapDescendentToInputEntry.
end() );
1041 if( find_input_entry_iter == mapDescendentToInputEntry.
end() ) {
1046 find_input_entry_iter->second;
1047 _ASSERT(candidate_input_entry);
1050 if( ! dest_input_entry ) {
1052 dest_input_entry = candidate_input_entry;
1053 }
else if( dest_input_entry == candidate_input_entry ) {
1059 bRemoveDendiag =
true;
1064 if( bRemoveDendiag ) {
1065 bAnyAlignChanged =
true;
1068 if( dest_input_entry != old_input_entry ) {
1069 bAnyAlignChanged =
true;
1071 mapEntryToDenseDiags[dest_input_entry].push_back(pDendiag);
1076 mapEntryToDenseDiags[old_input_entry].push_back(pDendiag);
1082 if( mapEntryToDenseDiags.size() == 1 )
1085 mapEntryToDenseDiags.begin()->first;
1086 mapEntryToAlignVec[dest_input_entry].push_back( align.
GetSeq_align() );
1092 entry_to_dendiags_iter,
1093 mapEntryToDenseDiags )
1096 entry_to_dendiags_iter->first;
1097 TDenseDiagVec & dendiag_vec = entry_to_dendiags_iter->second;
1098 _ASSERT( ! dendiag_vec.empty() );
1106 pNewAlign->
SetSegs().SetDendiag();
1107 ITERATE( TDenseDiagVec, dendiag_vec_it, dendiag_vec ) {
1109 pNewDendiag->Assign( **dendiag_vec_it );
1110 new_dendiag_vec.push_back( pNewDendiag );
1113 mapEntryToAlignVec[dest_input_entry].push_back( pNewAlign );
1116 bAnyAlignChanged =
true;
1119 return bAnyAlignChanged;
1128 bool bAnyAlignChanged =
false;
1134 typedef vector<CDense_seg::TDim> TRowVec;
1139 TMapInputEntryToDensegRows mapInputEntryToDensegRows;
1143 for(
size_t iRow = 0; iRow < ids.size(); ++iRow ) {
1151 mapDescendentToInputEntry.
find(id_bioseq_entry) :
1152 mapDescendentToInputEntry.
end() );
1153 if( find_input_entry_iter == mapDescendentToInputEntry.
end() ) {
1155 bAnyAlignChanged =
true;
1161 find_input_entry_iter->second;
1164 if( id_input_entry != old_input_entry ) {
1165 bAnyAlignChanged =
true;
1167 mapInputEntryToDensegRows[id_input_entry].push_back(iRow);
1170 if( ! bAnyAlignChanged ) {
1172 mapEntryToAlignVec[old_input_entry].push_back( align.
GetSeq_align() );
1176 ITERATE(TMapInputEntryToDensegRows,
1177 input_entry_to_denseg_it,
1178 mapInputEntryToDensegRows)
1181 input_entry_to_denseg_it->first;
1182 const TRowVec & rowVec = input_entry_to_denseg_it->second;
1190 pNewSeqAlign->
SetSegs().SetDenseg( *pNewDenseg );
1192 mapEntryToAlignVec[dest_input_entry].push_back( pNewSeqAlign );
1196 bAnyAlignChanged =
true;
1199 return bAnyAlignChanged;
1227 bool bAnyAlignNeedsChange =
false;
1231 for( ; align_ci; ++align_ci) {
1239 align, mapDescendentToInputEntry, mapEntryToAlignVec) )
1241 bAnyAlignNeedsChange =
true;
1248 align, mapDescendentToInputEntry, mapEntryToAlignVec) )
1250 bAnyAlignNeedsChange =
true;
1255 mapEntryToAlignVec[old_input_entry].push_back(align.
GetSeq_align());
1261 if( ! bAnyAlignNeedsChange ) {
1270 pOldAnnotWithNoAligns->
SetData().SetAlign().clear();
1274 ITERATE( TMapEntryToAlignVec::TKeyVec,
1275 entry_to_aligns_iter,
1276 mapEntryToAlignVec.GetKeysInOriginalOrder() )
1280 mapEntryToAlignVec.find(dest_input_entry)->second;
1285 pNewAnnot->
Assign(*pOldAnnotWithNoAligns);
1287 pNewAnnot->
SetData().SetAlign();
1289 _ASSERT( new_aligns.empty() );
1293 pNewAlign->
Assign( **align_it );
1294 new_aligns.push_back( pNewAlign );
1297 mapSeqAnnotToDest[pNewAnnot] = dest_input_entry;
1301 vecOfSeqAnnotToErase.push_back(annot_h);
1311 mapDescendentToInputEntry[*input_entry_iter] = *input_entry_iter;
1313 for(; descendent_entry_iter; ++descendent_entry_iter ) {
1314 mapDescendentToInputEntry[*descendent_entry_iter] = *input_entry_iter;
1330 for( ; annot_ci; ++annot_ci ) {
1333 mapDescendentToInputEntry,
1335 vecOfSeqAnnotsToErase );
1340 ITERATE(TMapSeqAnnotToDest::TKeyVec,
1342 mapSeqAnnotToDest.GetKeysInOriginalOrder() )
1345 const CSeq_entry_Handle & dest_entry_h = mapSeqAnnotToDest.find(pAnnot)->second;
1348 if( dest_entry_h ) {
1355 pAnnotCopy->
Assign(*pAnnot);
1356 input_entry_iter->GetEditHandle().AttachAnnot(*pAnnotCopy);
1363 annot_iter->GetEditHandle().Remove();
1370 if (
set.IsEmptySeq_set()) {
1377 if ((*it)->IsSetDescr()) {
1380 if (!(*d)->IsTitle() && !(*d)->IsMolinfo() && !(*d)->IsSource()) {
1384 master->
Set().push_back(cpy);
1390 CSeq_descr::Tdata::iterator d = master->
Set().begin();
1391 while (d != master->
Set().end()) {
1394 if ((*d)->Equals(**s)) {
1402 d = master->
Set().erase(d);
1411 if (master->
IsSet() && !master->
Set().empty()) {
1417 if ((*it)->IsSeq()) {
1420 CBioseq::TDescr::Tdata::iterator di = bse.
SetDescr().Set().begin();
1421 while (di != bse.
SetDescr().Set().end() && !(*di)->Equals(**d)) {
1424 if (di != bse.
SetDescr().Set().end()) {
1427 }
else if ((*it)->IsSet()) {
1430 CBioseq_set::TDescr::Tdata::iterator di = bsse.
SetDescr().Set().begin();
1431 while (di != bsse.
SetDescr().Set().end() && !(*di)->Equals(**d)) {
1434 if (di != bsse.
SetDescr().Set().end()) {
1449 const vector<CSeqdesc::E_Choice> &choices_to_delete )
1451 if( ! bioseq_set_h ) {
1457 stable_sort( sorted_choices_to_delete.begin(),
1458 sorted_choices_to_delete.end() );
1470 for( ; desc_ci; ++desc_ci ) {
1471 if( ! binary_search( sorted_choices_to_delete.begin(),
1472 sorted_choices_to_delete.end(), desc_ci->
Which() ) )
1475 pSeqDescrWithChosenDescs->
Set().push_back(
1479 pSeqDescrToCopy = pSeqDescrWithChosenDescs;
1484 for( ; direct_child_ci; ++direct_child_ci ) {
1546 switch (
id.Which()) {
1548 if (
id.GetLocal().IsStr()) {
1549 val =
id.GetLocal().GetStr();
1550 }
else if (
id.GetLocal().IsId()) {
1559 val =
id.AsFastaString();
1585 if (entry.
IsSeq()) {
1586 bool need_object =
true;
1592 need_object =
false;
1603 obj->
SetData().push_back(field);
1609 seq.
SetDescr().Set().push_back(desc);
1629 bool any_type =
false;
1630 bool found_mismatch =
false;
1639 if ((*id_it)->Which() == choice) {
1647 found_mismatch =
true;
1650 found_mismatch =
true;
1653 found_mismatch =
true;
1656 found_mismatch =
true;
1660 if (!found && (any_type || found_mismatch)) {
1672 for(
auto it: user.
GetData()) {
1686 if (entry.
IsSeq()) {
1713 if (entry.
IsSeq()) {
1716 if ((*desc_it)->IsUser() && (*desc_it)->GetUser().GetObjectType() ==
type) {
1727 if ((*desc_it)->IsUser() && (*desc_it)->GetUser().GetObjectType() ==
type) {
1751 ds->SetLiteral().SetSeq_data().SetIupacna().Set(element);
1752 ds->SetLiteral().SetLength(element.length());
1754 inst.
SetExt().SetDelta().Set().push_back(ds);
1761 if (is_assembly_gap)
1763 gap->SetLiteral().SetSeq_data().SetGap();
1764 gap->SetLiteral().SetSeq_data().SetGap().SetType(gap_type);
1767 gap->SetLiteral().SetSeq_data().SetGap().SetLinkage(linkage);
1769 if (linkage_evidence >= 0)
1772 link_ev->SetType(linkage_evidence);
1773 gap->SetLiteral().SetSeq_data().SetGap().SetLinkage_evidence().push_back(link_ev);
1779 gap->SetLiteral().SetLength(n_len);
1780 inst.
SetExt().SetDelta().Set().push_back(gap);
1805 size_t min_unknown,
int max_unknown,
1806 size_t min_known,
int max_known,
1807 bool is_assembly_gap,
int gap_type,
int linkage,
int linkage_evidence )
1840 ITERATE(
string, it, iupacna) {
1847 bool is_unknown =
false;
1848 bool is_known =
false;
1850 if (n_len >= min_unknown && (max_unknown < 0 || n_len <= max_unknown)) {
1852 }
else if (n_len >= min_known && (max_known < 0 || n_len <= max_known)) {
1855 if (is_unknown || is_known) {
1857 if (element.length() > n_len) {
1858 element = element.substr(0, element.length() - n_len);
1861 s_AddGap(inst, n_len, is_unknown, is_assembly_gap, gap_type, linkage, linkage_evidence);
1872 bool is_unknown =
false;
1873 bool is_known =
false;
1875 if (n_len >= min_unknown && (max_unknown < 0 || n_len <= max_unknown)) {
1877 }
else if (n_len >= min_known && (max_known < 0 || n_len <= max_known)) {
1880 if (is_unknown || is_known) {
1882 if (element.length() > n_len) {
1883 element = element.substr(0, element.length() - n_len);
1886 s_AddGap(inst, n_len, is_unknown, is_assembly_gap, gap_type, linkage, linkage_evidence);
1920 if ((*it)->IsLiteral()) {
1921 if ((*it)->GetLiteral().IsSetLength()) {
1922 orig_len = (*it)->GetLiteral().GetLength();
1924 if ((*it)->GetLiteral().IsSetFuzz()
1925 && orig_len != unknown_length
1926 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
1928 int diff = unknown_length - orig_len;
1929 (*it)->SetLiteral().SetLength(unknown_length);
1933 }
else if ((*it)->IsLoc()) {
1934 orig_len = (*it)->GetLoc().GetTotalRange().GetLength();
1945 size_t min_unknown,
int max_unknown,
1946 size_t min_known,
int max_known,
1947 bool is_assembly_gap,
int gap_type,
int linkage,
int linkage_evidence )
1952 ConvertRawToDeltaByNs(*inst, min_unknown, max_unknown, min_known, max_known, is_assembly_gap, gap_type, linkage, linkage_evidence);
1957 if (changes.size() > 0) {
1960 cpy->
Assign(*(
f->GetSeq_feat()));
1961 TLocAdjustmentVector::reverse_iterator it = changes.rbegin();
1963 bool trimmed =
false;
1964 while (it != changes.rend() && !cut) {
1965 if (it->second < 0) {
1993 if ((*it)->IsLiteral()
1994 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
1995 CSeq_gap& gap = (*it)->SetLiteral().SetSeq_data().SetGap();
2012 if ((*it)->IsLiteral()
2013 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
2014 CSeq_gap& gap = (*it)->SetLiteral().SetSeq_data().SetGap();
2024 if ((*it)->IsLiteral()
2025 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
2026 CSeq_gap& gap = (*it)->SetLiteral().SetSeq_data().SetGap();
2043 if ((*it)->IsLiteral()
2044 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
2045 CSeq_gap& gap = (*it)->SetLiteral().SetSeq_data().SetGap();
2060 if ((*it)->IsLiteral()
2061 && (!(*it)->GetLiteral().IsSetSeq_data() || (*it)->GetLiteral().GetSeq_data().IsGap())) {
2062 CSeq_gap& gap = (*it)->SetLiteral().SetSeq_data().SetGap();
2101 ss <<
"Nuc has invalid sequence length = " << nuc_len;
2105 TCuts::const_iterator cit;
2106 for (cit = cuts.begin(); cit != cuts.end(); ++cit) {
2107 const TRange& cut = *cit;
2110 if (cut_from < 0 || cut_to < 0 || cut_from >= nuc_len || cut_to >= nuc_len) {
2112 ss <<
"Cut location is invalid = [" << cut_from <<
" - " << cut_to <<
"]";
2120 const auto num_cuts = sorted_merged_cuts.size();
2121 _ASSERT(num_cuts==1 || num_cuts==2);
2124 const auto& first_cut = sorted_merged_cuts[0];
2125 if (num_cuts == 1) {
2126 if (first_cut.GetFrom() == 0) {
2127 range.SetFrom(first_cut.GetTo()+1);
2128 range.SetTo(seqLength-1);
2132 range.SetTo(first_cut.GetFrom()-1);
2138 _ASSERT(first_cut.GetFrom() > 0);
2139 range.SetTo(first_cut.GetFrom()-1);
2140 range.SetFrom(sorted_merged_cuts[1].GetTo()+1);
2156 GetSortedCuts(bsh, cuts, sorted_cuts, internal_cut_conversion);
2170 for (; feat_ci; ++feat_ci) {
2177 bool bFeatureDeleted =
false;
2180 bool bFeatureTrimmed =
false;
2183 bool isPartialStart =
false;
2184 bool isPartialStop =
false;
2185 TrimSeqFeat(copy_feat, sorted_cuts, bFeatureDeleted, bFeatureTrimmed, isPartialStart, isPartialStop);
2187 if (bFeatureDeleted) {
2194 if (bFeatureTrimmed) {
2210 auto new_frame = sequence::CFeatTrim::GetCdsFrame(original_feat, retainedRange);
2211 copy_feat->
SetData().SetCdregion().SetFrame(new_frame);
2213 RetranslateCdregion(bsh, isPartialStart, isPartialStop, copy_inst, copy_feat, sorted_cuts);
2225 for (; align_ci; ++align_ci) {
2255 for (; graph_ci; ++graph_ci) {
2332 for (it = sorted_cuts.begin(); it != sorted_cuts.end(); ) {
2337 if ( it+1 != sorted_cuts.end() ) {
2338 TRange& next_cut = *(it+1);
2342 if ( next_from <= (to + 1) ) {
2346 sorted_cuts.erase(it+1);
2369 for (TCuts::size_type ii = 0; ii < cuts.size(); ++ii) {
2375 if (from != 0 && to != seq_length-1) {
2378 if (from - 0 < seq_length-1 - to) {
2382 cut.
SetTo(seq_length-1);
2392 cut.
SetTo(seq_length-1);
2412 for (TCuts::size_type ii = 0; ii < cuts.size(); ++ii) {
2413 const TRange& cut = cuts[ii];
2418 sorted_cuts.push_back(cut);
2431 sort(sorted_cuts.begin(), sorted_cuts.end(), asc);
2435 internal_cut_conversion);
2448 sort(sorted_cuts.begin(), sorted_cuts.end(), descend);
2458 switch (seqmap_ci.
GetType()) {
2468 if (pOriginalGapSeqLiteral) {
2469 pNewGapLiteral->Assign(*pOriginalGapSeqLiteral);
2471 if (!bIsLengthKnown) {
2474 pNewGapLiteral->SetLength(uGapLength);
2475 pDeltaSeq->SetLiteral(*pNewGapLiteral);
2477 new_length += uGapLength;
2491 pDeltaSeq->SetLiteral().SetLength(seqmap_ci.
GetLength());
2492 pDeltaSeq->SetLiteral().SetSeq_data(*pSeqData);
2504 const TCuts& sorted_cuts)
2520 for (
const auto& cut : sorted_cuts) {
2521 if (cut.GetTo() == right_pos) {
2522 right_pos = cut.GetFrom() - 1;
2525 if (cut.GetFrom() == left_pos) {
2526 left_pos = cut.GetTo() + 1;
2534 1 + (right_pos - left_pos),
2542 for (; seqmap_ci; ++seqmap_ci) {
2545 if (! seqmap_ci_first)
2547 seqmap_ci_first = seqmap_ci;
2551 seqmap_ci_last = seqmap_ci;
2558 for (seqmap_ci = seqmap_ci_first; seqmap_ci && seqmap_ci != seqmap_ci_last; ++seqmap_ci) {
2561 if (seqmap_ci_last) {
2571 if (pDeltaExt->
Set().size() == 1) {
2575 CSeq_data& seq_data = pDeltaSeq->SetLiteral().SetSeq_data();
2580 inst->
SetExt().SetDelta(*pDeltaExt);
2586 const TCuts& sorted_cuts,
2596 for (TCuts::size_type ii = 0; ii < sorted_cuts.size(); ++ii) {
2597 const TRange& cut = sorted_cuts[ii];
2603 if ( trim_start <= to ) {
2604 trim_start = to + 1;
2610 if ( trim_stop >= from ) {
2611 trim_stop = from - 1;
2634 TSeqPos cut_size = cut_to - cut_from + 1;
2637 if (feat_to < cut_from)
2644 if (feat_from >= cut_from && feat_to <= cut_to)
2647 bCompleteCut =
true;
2652 if (feat_from > cut_to)
2655 feat_from -= cut_size;
2656 feat_to -= cut_size;
2658 interval->
SetTo(feat_to);
2673 if (feat_to > cut_to) {
2675 feat_to -= cut_size;
2679 feat_to = cut_from - 1;
2683 if (feat_from >= cut_from) {
2684 feat_from = cut_to + 1;
2685 feat_from -= cut_size;
2689 interval->
SetTo(feat_to);
2702 switch(loc->
Which())
2719 if (intervals->CanGet()) {
2721 CPacked_seqint::Tdata::iterator it;
2722 for (it = intervals->Set().begin();
2723 it != intervals->Set().end(); )
2729 if (it == intervals->Set().begin()) {
2730 bCompleteCut =
true;
2733 bool bDeleted =
false;
2738 it = intervals->Set().erase(it);
2742 bCompleteCut =
false;
2756 mix->Assign(loc->
GetMix());
2757 if (mix->CanGet()) {
2759 CSeq_loc_mix::Tdata::iterator it;
2760 for (it = mix->Set().begin();
2761 it != mix->Set().end(); )
2767 if (it == mix->Set().begin()) {
2768 bCompleteCut =
true;
2771 bool bDeleted =
false;
2776 it = mix->Set().erase(it);
2780 bCompleteCut =
false;
2800 const TCuts& sorted_cuts)
2802 for (TCuts::size_type ii = 0; ii < sorted_cuts.size(); ++ii) {
2803 const TRange& cut = sorted_cuts[ii];
2809 new_loc->Assign(graph->
GetLoc());
2810 bool bDeleted =
false;
2811 bool bTrimmed =
false;
2822 const TCuts& sorted_cuts)
2834 TSeqPos copy_start = graph_start;
2835 if (trim_start > graph_start) {
2836 copy_start = trim_start;
2838 TSeqPos copy_stop = graph_stop;
2839 if (trim_stop < graph_stop) {
2840 copy_stop = trim_stop;
2851 copy_start -= graph_start;
2852 copy_stop -= graph_start;
2863 graph->
SetNumval(copy_stop - copy_start + 1);
2877 for (seg = 0; seg < denseg.
GetNumseg(); ++seg) {
2881 if (pos >= start && pos < start +
len) {
2905 if ( !
s_FindSegment(denseg, row, pos, foundseg, seg_start) ) {
2911 if (pos == seg_start) {
2958 TSeqPos first_len, second_len;
2962 first_len = pos - seg_start;
2963 second_len = denseg.
GetLens()[foundseg] - first_len;
2966 second_len = pos - seg_start;
2967 first_len = denseg.
GetLens()[foundseg] - second_len;
2988 new_denseg->
SetLens().push_back(first_len);
3006 new_denseg->
SetLens().push_back(second_len);
3032 align->
SetSegs().SetDenseg(*new_denseg);
3039 const TCuts& sorted_cuts)
3048 for (CDense_seg::TIds::size_type rr = 0; rr < ids.size(); ++rr) {
3049 if (ids[rr]->Match( *(bsh.
GetSeqId()) )) {
3059 for (TCuts::size_type ii = 0; ii < sorted_cuts.size(); ++ii) {
3060 const TRange& cut = sorted_cuts[ii];
3064 TSeqPos cut_len = cut_to - cut_from + 1;
3065 if (cut_to < cut_from) {
3066 cut_len = cut_from - cut_to + 1;
3082 if (seg_start < 0) {
3085 else if (seg_start < cut_from) {
3088 else if (seg_start >= cut_from &&
3089 seg_start + denseg.
GetLens()[curseg] <= cut_from + cut_len) {
3091 align->
SetSegs().SetDenseg().SetStarts()[index] = -1;
3095 align->
SetSegs().SetDenseg().SetStarts()[index] -= cut_len;
3105 swap(partial_start, partial_stop);
3108 if (partial_start) {
3115 if (partial_start || partial_stop) {
3124 for (TCuts::size_type ii = 0; ii < sorted_cuts.size(); ++ii) {
3125 const TRange& cut = sorted_cuts[ii];
3139 partial_start =
true;
3145 partial_stop =
true;
3147 s_SeqLocDelete(new_location, from, to, bFeatureDeleted, bFeatureTrimmed);
3149 if (bFeatureTrimmed) {
3158 if (bFeatureDeleted) {
3167 bool bProdDeleted =
false;
3168 bool bProdTrimmed =
false;
3169 s_SeqLocDelete(new_product, from, to, bProdDeleted, bProdTrimmed);
3225 const TCuts& sorted_cuts)
3228 bool bIsPartialStart =
false;
3235 for (TCuts::size_type ii = 0; ii < sorted_cuts.size(); ++ii) {
3236 const TRange& cut = sorted_cuts[ii];
3252 to == original_nuc_len - 1 &&
3259 TSeqPos old_frame = new_cdregion->GetFrame();
3260 if (old_frame == 0) {
3264 TSignedSeqPos new_frame = old_frame - ((to - from + 1) % 3);
3265 if (new_frame < 1) {
3272 cds->
SetData().SetCdregion(*new_cdregion);
3291 if (!new_protein_bioseq) {
3307 return new_protein_bioseq;
3314 bool isPartialStart,
3318 const TCuts& sorted_cuts)
3334 bseh.
SetInst(*trimmed_nuc_inst);
3350 if ( !new_protein_bioseq ) {
3362 if (partial5 && partial3) {
3374 CBioseq::TDescr::Tdata::iterator it;
3375 for (it = prot_eh.
SetDescr().Set().begin(); it != prot_eh.
SetDescr().Set().end(); ++it) {
3376 if ((*it)->IsMolinfo()) {
3384 (*it)->SetMolinfo().SetCompleteness(completeness);
3392 (*it)->SetMolinfo().SetCompleteness(completeness);
3401 prot_eh.
SetDescr().Set().push_back(desc);
3407 CFeat_CI prot_feat_ci(prot_bsh, sel);
3408 for ( ; prot_feat_ci; ++prot_feat_ci ) {
3432 prot_feat_eh.
Replace(*new_feat);
3469 if (it->IsUser() && it->GetUser().IsUnverifiedOrganism()) {
3483 if (it->IsUser() && it->GetUser().IsUnverifiedFeature()) {
3496 if (it->IsUser() && it->GetUser().IsUnverifiedMisassembled()) {
3510 if (it->IsUser() && it->GetUser().IsUnverifiedContaminant()) {
3520 descr.
Set().sort(CompareSeqdesc());
3550 if (
prot.IsSetName() &&
3551 prot.GetName().size() > 0) {
3552 return prot.GetName().front();
3563 return rna.GetRnaProductName();
3590 for (
auto it : feat.
GetQual()) {
3591 if (it->IsSetQual() &&
NStr::EqualNocase(it->GetQual(),
"mobile_element_type") && it->IsSetVal()) {
3594 if (pos != string::npos) {
3595 tln = tln.substr(pos + 1);
3618 if (gene_for_feat) {
3639 while (
f && !quit) {
3640 switch (
f->GetData().Which()) {
3668 if ((*it)->IsUser() &&
3675 (*it)->SetUser().Assign(*new_obj);
3688 bh.
SetDescr().Set().push_back(new_desc);
3721 vector<string> tokens1;
3723 vector<string> tokens2;
3727 size_t t1_match_start = string::npos;
3728 size_t t1_match_end = 0;
3729 ITERATE(vector<string>, it1, tokens1){
3730 ITERATE(vector<string>, it2, tokens2) {
3732 t1_match_start = t1_pos;
3733 t1_match_end = t1_pos;
3736 while (it1 != tokens1.end() && it2 != tokens2.end() &&
NStr::Equal(*it1, *it2)) {
3744 if (t1_match_start != string::npos) {
3750 if (t1_match_start == string::npos) {
3755 size_t start_pos = 0;
3756 string::const_iterator s = tls1.begin();
3757 while (s != tls1.end() && (*s ==
' ' || *s ==
',' || *s ==
'-')) {
3762 while (
i < t1_match_start) {
3763 start_pos += tokens1[
i].length();
3764 for (
size_t k = 0; k < tokens1[
i].length(); k++) {
3767 while (s != tls1.end() && (*s ==
' ' || *s ==
',' || *s ==
'-')) {
3773 size_t match_len = tokens1[
i].length();
3774 for (
size_t k = 0; k < tokens1[
i].length(); k++) {
3779 while (
i <= t1_match_end) {
3780 while (s != tls1.end() && (*s ==
' ' || *s ==
',' || *s ==
'-')) {
3784 match_len += tokens1[
i].length();
3785 for (
size_t k = 0; k < tokens1[
i].length(); k++) {
3791 string consensus = tls1.substr(start_pos, match_len);
User-defined methods of the data storage class.
@ eExtreme_Positional
numerical value
@ eExtreme_Biological
5' and 3'
User-defined methods of the data storage class.
User-defined methods of the data storage class.
CRef< CUser_object > MakeUserObject() const
void InitFromUserObject(const CUser_object &obj)
void SetTargetedLocusName(const string &tls)
void Set(T *object)
Initialize with an existing object.
CBioseq_set_EditHandle –.
TSeqPos GetLength(void) const
CRef< CDense_seg > ExtractRows(const vector< TDim > &rows) const
Extract specified rows of the alignment, in specified order.
@RNA_ref.hpp User-defined methods of the data storage class.
Helper functor to compare cuts during sorting.
bool operator()(const TRange &a1, const TRange &a2)
CRangeCmp(ESortOrder sortorder=eAscending)
static SIZE_TYPE Convert(const CTempString &src, TCoding src_coding, TSeqPos pos, TSeqPos length, string &dst, TCoding dst_coding)
ESubtype GetSubtype(void) const
@ eSubtype_mobile_element
@Seq_descr.hpp User-defined methods of the data storage class.
void SetDescr(CSeq_descr &value)
void ReassignConflictingIds(void)
bool IsSetDescr(void) const
namespace ncbi::objects::
bool AddLinkageEvidence(CLinkage_evidence::TType evidence_type)
void ChangeType(TType linkage_type)
void SetLinkageTypeLinkedRepeat(CLinkage_evidence::TType evidence_type)
void SetLinkageTypeScaffold(CLinkage_evidence::TType evidence_type)
bool IsEntrys(void) const
static TSeqPos Pack(CSeq_data *in_seq, TSeqPos uLength=ncbi::numeric_limits< TSeqPos >::max())
void SetObjectType(EObjectType obj_type)
@ eObjectType_AutodefOptions
container_type::const_iterator const_iterator
container_type::iterator iterator
container_type::mapped_type & operator[](const key_type &key)
const_iterator end() const
iterator_bool insert(const value_type &val)
container_type::value_type value_type
const_iterator find(const key_type &key) const
iterator_bool insert(const value_type &val)
const_iterator find(const key_type &key) const
const_iterator end() const
Include a standard set of the NCBI C++ Toolkit most basic headers.
static const char si[8][64]
static DLIST_TYPE *DLIST_NAME() first(DLIST_LIST_TYPE *list)
unsigned int TSeqPos
Type for sequence locations and lengths.
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
int TSignedSeqPos
Type for signed sequence position.
#define NON_CONST_ITERATE(Type, Var, Cont)
Non constant version of ITERATE macro.
void swap(NCBI_NS_NCBI::pair_base_member< T1, T2 > &pair1, NCBI_NS_NCBI::pair_base_member< T1, T2 > &pair2)
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
virtual void Assign(const CSerialObject &source, ESerialRecursionMode how=eRecursive)
Set object to copy of another one.
const TPrim & Get(void) const
C * SerialClone(const C &src)
Create on heap a clone of the source object.
#define MSerial_AsnText
I/O stream manipulators –.
void SetPacked_int(TPacked_int &v)
bool IsPartialStart(ESeqLocExtremes ext) const
check start or stop of location for e_Lim fuzz
ENa_strand GetStrand(void) const
Get the location's strand.
TRange GetTotalRange(void) const
TSeqPos GetStart(ESeqLocExtremes ext) const
Return start and stop positions of the seq-loc.
void SetPartialStart(bool val, ESeqLocExtremes ext)
set / remove e_Lim fuzz on start or stop (lt/gt - indicating partial interval)
void SetPartialStop(bool val, ESeqLocExtremes ext)
bool IsPartialStop(ESeqLocExtremes ext) const
TSeqPos GetStop(ESeqLocExtremes ext) const
TSeqPos GetStop(const CSeq_loc &loc, CScope *scope, ESeqLocExtremes ext=eExtreme_Positional)
If only one CBioseq is represented by CSeq_loc, returns the position at the stop of the location.
const CSeq_id & GetId(const CSeq_loc &loc, CScope *scope)
If all CSeq_ids embedded in CSeq_loc refer to the same CBioseq, returns the first CSeq_id found,...
TSeqPos GetLength(const CSeq_id &id, CScope *scope)
Get sequence length if scope not null, else return max possible TSeqPos.
TSeqPos GetStart(const CSeq_loc &loc, CScope *scope, ESeqLocExtremes ext=eExtreme_Positional)
If only one CBioseq is represented by CSeq_loc, returns the position at the start of the location.
static CRef< CBioseq > TranslateToProtein(const CSeq_feat &cds, CScope &scope)
CConstRef< CSeq_feat > GetGeneForFeature(const CSeq_feat &feat, CScope &scope)
Finds gene for feature, but obeys SeqFeatXref directives.
CBioseq_Handle AddBioseq(CBioseq &bioseq, TPriority pri=kPriority_Default, EExist action=eExist_Throw)
Add bioseq, return bioseq handle.
void RemoveBioseq(const CBioseq_Handle &seq)
Revoke Bioseq previously added using AddBioseq().
CBioseq_Handle GetBioseqHandle(const CSeq_id &id)
Get bioseq handle by seq-id.
vector< CBioseq_Handle > TBioseqHandles
CBioseq_set_EditHandle GetEditHandle(void) const
Get 'edit' version of handle.
TSeq ConvertSetToSeq(void) const
Do the same as CollapseSet() when sub-entry is of type bioseq.
bool IsNucleotide(void) const
void SetDescr(TDescr &v) const
CConstRef< CBioseq > GetCompleteBioseq(void) const
Get the complete bioseq.
TClass GetClass(void) const
const TInst_Ext & GetInst_Ext(void) const
CBioseq_set_Handle GetParentBioseq_set(void) const
Return a handle for the parent Bioseq-set, or null handle.
CSeq_entry_Handle GetParentEntry(void) const
Get parent Seq-entry handle.
void SetDescr(TDescr &v) const
CBioseq_EditHandle MoveTo(const CSeq_entry_EditHandle &entry, int index=-1) const
Move current bioseq into seq-entry.
void SetClass(TClass v) const
void AddDescr(TDescr &v) const
void SetInst_Mol(TInst_Mol v) const
void ResetDescr(void) const
bool IsEmptySeq_set(void) const
Check if the bioseq set is empty.
CScope & GetScope(void) const
Get scope this handle belongs to.
const CSeqFeatData & GetData(void) const
bool CanGetInst(void) const
TSeqPos GetBioseqLength(void) const
void Replace(const CSeq_align &new_obj) const
Replace the Seq-align with new Seq-align object.
bool AddSeqdesc(CSeqdesc &d) const
CSeq_entry_EditHandle TakeEntry(const CSeq_entry_EditHandle &entry, int index=-1) const
Remove seq-entry from its location and attach to current one.
CSeq_annot_EditHandle AttachAnnot(CSeq_annot &annot) const
Attach an annotation.
TSet ConvertSeqToSet(TClass set_class=CBioseq_set::eClass_not_set) const
Convert the entry from Bioseq to Bioseq-set.
void TakeAllAnnots(const CSeq_entry_EditHandle &src_entry) const
Remove all the annotation from seq-entry and attach to current one.
void AddSeq_descr(TDescr &v) const
void SetInst_Length(TInst_Length v) const
void Remove(void) const
Remove the feature from Seq-annot.
CConstRef< CSeq_annot > GetCompleteSeq_annot(void) const
Complete and return const reference to the current seq-annot.
TInst_Mol GetInst_Mol(void) const
const CSeq_align::TSegs & GetSegs(void) const
bool IsSetProduct(void) const
CConstRef< CSeq_align > GetSeq_align(void) const
Get const reference to current seq-align.
CConstRef< CSeq_id > GetSeqId(void) const
Get id which can be used to access this bioseq handle Throws an exception if none is available.
void SetInst(TInst &v) const
void Remove(ERemoveMode mode=eRemoveSeq_entry) const
CBioseq_set_Handle GetParentBioseq_set(void) const
Get parent bioseq-set handle.
bool IsRemoved(void) const
Check if handle points to a removed bioseq.
CSeq_entry_Handle GetParentEntry(void) const
Get parent Seq-entry handle.
bool IsProtein(void) const
void SetInst_Repr(TInst_Repr v) const
CBioseq_EditHandle TakeBioseq(const CBioseq_EditHandle &seq, int index=-1) const
Remove bioseq from its location and attach to current one.
CSeq_entry_EditHandle GetEditHandle(void) const
Get 'edit' version of handle.
CBioseq_EditHandle GetEditHandle(void) const
Get 'edit' version of handle.
CSeq_entry_Handle GetParentEntry(void) const
Return a handle for the parent seq-entry of the bioseq.
TInst_Length GetInst_Length(void) const
CSeq_entry_EditHandle AttachEntry(CSeq_entry &entry, int index=-1) const
Attach an existing seq-entry.
bool IsSetInst_Repr(void) const
bool IsSetClass(void) const
CRef< CSeqdesc > RemoveSeqdesc(const CSeqdesc &d) const
CScope & GetScope(void) const
Get scope this handle belongs to.
TInst_Repr GetInst_Repr(void) const
CRef< CSeqdesc > RemoveSeqdesc(const CSeqdesc &d) const
CScope & GetScope(void) const
Get scope this handle belongs to.
CBioseq_EditHandle TakeBioseq(const CBioseq_EditHandle &seq, int index=-1) const
Remove bioseq from its location and attach to current one.
CSeq_annot_EditHandle AttachAnnot(CSeq_annot &annot) const
Attach an annotation.
CScope & GetScope(void) const
Get scope this handle belongs to.
CSeq_entry_EditHandle GetParentEntry(void) const
Navigate object tree.
void SetInst_Ext(TInst_Ext &v) const
CBioseq_EditHandle AttachBioseq(CBioseq &seq, int index=-1) const
Attach an existing bioseq.
const CSeqMap & GetSeqMap(void) const
Get sequence map.
bool HasParentEntry(void) const
Check if current seq-entry has a parent.
CSeq_entry_Handle GetTopLevelEntry(void) const
Get top level Seq-entry handle.
void Replace(const CSeq_feat &new_feat) const
Replace the feature with new Seq-feat object.
CSeq_entry_Handle GetParentEntry(void) const
Get parent Seq-entry handle.
const CSeq_annot_Handle & GetAnnot(void) const
Get handle to the seq-annot.
CSeq_entry_EditHandle GetParentEntry(void) const
Navigate object tree.
bool IsSetData(void) const
CConstRef< CBioseq_set > GetBioseq_setCore(void) const
Return core data for the bioseq-set.
void Replace(const CSeq_graph &new_obj) const
Replace the Seq-graph with new Seq-graph object.
bool CanGetInst_Ext(void) const
int GetSeq_entry_Index(const CSeq_entry_Handle &handle) const
const TInst & GetInst(void) const
@ eCoding_Iupac
Set coding to printable coding (Iupacna or Iupacaa)
TSeqPos GetEndPosition(void) const
return end position of current segment in sequence (exclusive)
const string & GetTitle(void) const
bool IsSetTitle(void) const
const CSeq_align & GetOriginalSeq_align(void) const
Get original alignment.
const CSeq_feat & GetOriginalFeature(void) const
Get original feature with unmapped location/product.
const CSeq_loc & GetProduct(void) const
CSeqMap::ESegmentType GetType(void) const
bool IsUnknownLength(void) const
return true if current segment is a gap of unknown length
const CSeq_graph & GetOriginalGraph(void) const
Get original graph with unmapped location/product.
vector< CSeqdesc::E_Choice > TDescChoices
CSeq_align_Handle GetSeq_align_Handle(void) const
Get original alignment handle.
TSeqPos GetPosition(void) const
return position of current segment in sequence
TSeqPos GetLength(void) const
return length of current segment
CConstRef< CSeq_literal > GetRefGapLiteral(void) const
return CSeq_literal with gap data, or null if either the segment is not a gap, or an unspecified gap
CSeq_graph_Handle GetSeq_graph_Handle(void) const
Get original graph handle.
@ eNonRecursive
Deprecated.
void GetSeqData(TSeqPos start, TSeqPos stop, string &buffer) const
Fill the buffer string with the sequence data for the interval [start, stop).
CSeqMap_CI ResolvedRangeIterator(CScope *scope, TSeqPos from, TSeqPos length, ENa_strand strand=eNa_strand_plus, size_t maxResolve=size_t(-1), TFlags flags=fDefaultFlags) const
Iterate segments in the range with specified strand coordinates.
const_iterator begin(void) const
@ eSeqData
real sequence data
bool IsNull(void) const THROWS_NONE
Check if pointer is null – same effect as Empty().
CRef< C > Ref(C *object)
Helper functions to get CRef<> and CConstRef<> objects.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define BEGIN_SCOPE(ns)
Define a new scope.
static int CompareNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive compare of a substring with another string.
static list< string > & Split(const CTempString str, const CTempString delim, list< string > &arr, TSplitFlags flags=0, vector< SIZE_TYPE > *token_pos=NULL)
Split a string using specified delimiters.
static bool EndsWith(const CTempString str, const CTempString end, ECase use_case=eCase)
Check if a string ends with a specified suffix value.
static bool IsBlank(const CTempString str, SIZE_TYPE pos=0)
Check if a string is blank (has no text).
static void TruncateSpacesInPlace(string &str, ETrunc where=eTrunc_Both)
Truncate spaces in a string (in-place)
static SIZE_TYPE Find(const CTempString str, const CTempString pattern, ECase use_case=eCase, EDirection direction=eForwardSearch, SIZE_TYPE occurrence=0)
Find the pattern in the string.
static bool StartsWith(const CTempString str, const CTempString start, ECase use_case=eCase)
Check if a string starts with a specified prefix value.
static bool EqualNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive equality of a substring with another string.
static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)
Convert numeric value to string.
static bool Equal(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2, ECase use_case=eCase)
Test for equality of a substring with another string.
@ fSplit_Tokenize
All delimiters are merged and trimmed, to get non-empty tokens only.
static const char label[]
void SetFrom(TFrom value)
Assign a value to From data member.
TTo GetTo(void) const
Get the To member data.
TFrom GetFrom(void) const
Get the From member data.
void SetTo(TTo value)
Assign a value to To data member.
bool IsSetLocus(void) const
Official gene symbol Check if a value has been assigned to Locus data member.
const TLocus & GetLocus(void) const
Get the Locus member data.
const TStr & GetStr(void) const
Get the variant data.
bool IsSetData(void) const
the object itself Check if a value has been assigned to Data data member.
bool IsStr(void) const
Check if variant Str is selected.
const TData & GetData(void) const
Get the Data member data.
bool IsStr(void) const
Check if variant Str is selected.
bool IsSetLabel(void) const
field label Check if a value has been assigned to Label data member.
TData & SetData(void)
Assign a value to Data data member.
const TStr & GetStr(void) const
Get the variant data.
void SetLabel(TLabel &value)
Assign a value to Label data member.
const TData & GetData(void) const
Get the Data member data.
void SetData(TData &value)
Assign a value to Data data member.
const TLabel & GetLabel(void) const
Get the Label member data.
bool IsSetData(void) const
Check if a value has been assigned to Data data member.
TSub & SetSub(void)
Select the variant.
bool CanGetDim(void) const
Check if it is safe to call GetDim method.
const TDenseg & GetDenseg(void) const
Get the variant data.
TLens & SetLens(void)
Assign a value to Lens data member.
E_Choice Which(void) const
Which variant is currently selected.
bool IsSetStrands(void) const
Check if a value has been assigned to Strands data member.
void ResetSegs(void)
Reset Segs data member.
const TStarts & GetStarts(void) const
Get the Starts member data.
void SetSegs(TSegs &value)
Assign a value to Segs data member.
const TLens & GetLens(void) const
Get the Lens member data.
bool CanGetNumseg(void) const
Check if it is safe to call GetNumseg method.
void SetDim(TDim value)
Assign a value to Dim data member.
bool CanGetIds(void) const
Check if it is safe to call GetIds method.
vector< CRef< CSeq_id > > TIds
vector< CRef< CSeq_id > > TIds
bool IsDendiag(void) const
Check if variant Dendiag is selected.
bool CanGetSegs(void) const
Check if it is safe to call GetSegs method.
TDim GetDim(void) const
Get the Dim member data.
TStarts & SetStarts(void)
Assign a value to Starts data member.
TStrands & SetStrands(void)
Assign a value to Strands data member.
const TDendiag & GetDendiag(void) const
Get the variant data.
void SetNumseg(TNumseg value)
Assign a value to Numseg data member.
const TIds & GetIds(void) const
Get the Ids member data.
bool CanGetStarts(void) const
Check if it is safe to call GetStarts method.
TNumseg GetNumseg(void) const
Get the Numseg member data.
TIds & SetIds(void)
Assign a value to Ids data member.
list< CRef< CDense_diag > > TDendiag
const TStrands & GetStrands(void) const
Get the Strands member data.
const TSegs & GetSegs(void) const
Get the Segs member data.
bool CanGetLens(void) const
Check if it is safe to call GetLens method.
bool IsDenseg(void) const
Check if variant Denseg is selected.
bool IsSetComment(void) const
Check if a value has been assigned to Comment data member.
bool IsSetData(void) const
the specific data Check if a value has been assigned to Data data member.
bool IsSetQual(void) const
qualifiers Check if a value has been assigned to Qual data member.
E_Choice Which(void) const
Which variant is currently selected.
void SetLocation(TLocation &value)
Assign a value to Location data member.
bool IsCdregion(void) const
Check if variant Cdregion is selected.
void SetPartial(TPartial value)
Assign a value to Partial data member.
void SetProduct(TProduct &value)
Assign a value to Product data member.
const TQual & GetQual(void) const
Get the Qual member data.
const TLocation & GetLocation(void) const
Get the Location member data.
const TData & GetData(void) const
Get the Data member data.
bool CanGetData(void) const
Check if it is safe to call GetData method.
void SetData(TData &value)
Assign a value to Data data member.
bool CanGetLocation(void) const
Check if it is safe to call GetLocation method.
const TCdregion & GetCdregion(void) const
Get the variant data.
const TProduct & GetProduct(void) const
Get the Product member data.
const TComment & GetComment(void) const
Get the Comment member data.
const TGene & GetGene(void) const
Get the variant data.
const TProt & GetProt(void) const
Get the variant data.
bool CanGetProduct(void) const
Check if it is safe to call GetProduct method.
const TRna & GetRna(void) const
Get the variant data.
bool IsSetProduct(void) const
product of process Check if a value has been assigned to Product data member.
void SetTo(TTo value)
Assign a value to To data member.
ENa_strand
strand of nucleic acid
TFrom GetFrom(void) const
Get the From member data.
bool CanGetTo(void) const
Check if it is safe to call GetTo method.
E_Choice Which(void) const
Which variant is currently selected.
void SetFrom(TFrom value)
Assign a value to From data member.
TTo GetTo(void) const
Get the To member data.
bool IsInt(void) const
Check if variant Int is selected.
const TInt & GetInt(void) const
Get the variant data.
const TMix & GetMix(void) const
Get the variant data.
const TPacked_int & GetPacked_int(void) const
Get the variant data.
bool CanGetFrom(void) const
Check if it is safe to call GetFrom method.
@ e_Other
for historical reasons, 'other' = 'refseq'
@ e_General
for other databases
@ e_not_set
No variant selected.
TByte & SetByte(void)
Select the variant.
void SetNumval(TNumval value)
Assign a value to Numval data member.
TValues & SetValues(void)
Assign a value to Values data member.
const TByte & GetByte(void) const
Get the variant data.
void SetGraph(TGraph &value)
Assign a value to Graph data member.
bool CanGetLoc(void) const
Check if it is safe to call GetLoc method.
const TValues & GetValues(void) const
Get the Values member data.
bool IsByte(void) const
Check if variant Byte is selected.
void SetLoc(TLoc &value)
Assign a value to Loc data member.
const TLoc & GetLoc(void) const
Get the Loc member data.
const TSeq & GetSeq(void) const
Get the variant data.
bool IsSetClass(void) const
Check if a value has been assigned to Class data member.
TSet & SetSet(void)
Select the variant.
TClass GetClass(void) const
Get the Class member data.
const TSet & GetSet(void) const
Get the variant data.
bool IsSeq(void) const
Check if variant Seq is selected.
bool IsSetSeq_set(void) const
Check if a value has been assigned to Seq_set data member.
bool IsSet(void) const
Check if variant Set is selected.
const TSeq_set & GetSeq_set(void) const
Get the Seq_set member data.
void SetClass(TClass value)
Assign a value to Class data member.
list< CRef< CSeq_entry > > TSeq_set
TSeq & SetSeq(void)
Select the variant.
TSeq_set & SetSeq_set(void)
Assign a value to Seq_set data member.
@ eClass_equiv
a set of equivalent maps or seqs
@ eClass_parts
parts for 2 or 3
@ eClass_pop_set
population study
@ eClass_phy_set
phylogenetic study
@ eClass_conset
constructed sequence + parts
@ eClass_wgs_set
whole genome shotgun project
@ eClass_mut_set
set of mutations
@ eClass_pir
converted pir
@ eClass_eco_set
ecological sample study
@ eClass_nuc_prot
nuc acid and coded proteins
@ eClass_gibb
geninfo backbone
@ eClass_gen_prod_set
genomic products, chrom+mRNA+protein
@ eClass_pdb_entry
a complete PDB entry
@ eClass_genbank
converted genbank
@ eClass_swissprot
converted SWISSPROT
@ eClass_segset
segmented sequence + parts
@ eClass_pub_set
all the seqs from a single publication
const TIupacaa & GetIupacaa(void) const
Get the variant data.
void SetCompleteness(TCompleteness value)
Assign a value to Completeness data member.
TRepr GetRepr(void) const
Get the Repr member data.
const TSeg & GetSeg(void) const
Get the variant data.
void SetData(TData &value)
Assign a value to Data data member.
list< CRef< CSeqdesc > > Tdata
TId & SetId(void)
Assign a value to Id data member.
void ResetDescr(void)
Reset Descr data member.
bool IsSetSeq_data(void) const
the sequence Check if a value has been assigned to Seq_data data member.
bool IsNcbieaa(void) const
Check if variant Ncbieaa is selected.
void SetPub(TPub &value)
Assign a value to Pub data member.
const TInst & GetInst(void) const
Get the Inst member data.
TPub & SetPub(void)
Select the variant.
bool IsIupacaa(void) const
Check if variant Iupacaa is selected.
const TIupacna & GetIupacna(void) const
Get the variant data.
void SetExt(TExt &value)
Assign a value to Ext data member.
bool IsSetRepr(void) const
Check if a value has been assigned to Repr data member.
TType GetType(void) const
Get the Type member data.
const TPub & GetPub(void) const
Get the variant data.
Tdata & Set(void)
Assign a value to data member.
bool CanGetLength(void) const
Check if it is safe to call GetLength method.
const TId & GetId(void) const
Get the Id member data.
bool IsSetExt(void) const
extensions for special types Check if a value has been assigned to Ext data member.
list< CRef< CSeq_align > > TAlign
const Tdata & Get(void) const
Get the member data.
TDelta & SetDelta(void)
Select the variant.
Tdata & Set(void)
Assign a value to data member.
TIupacna & SetIupacna(void)
Select the variant.
TLength GetLength(void) const
Get the Length member data.
list< CRef< CSeq_id > > TId
const TNcbieaa & GetNcbieaa(void) const
Get the variant data.
bool IsDelta(void) const
Check if variant Delta is selected.
void ResetLinkage(void)
Reset Linkage data member.
bool IsSetType(void) const
Check if a value has been assigned to Type data member.
const TExt & GetExt(void) const
Get the Ext member data.
bool IsSetDescr(void) const
descriptors Check if a value has been assigned to Descr data member.
bool IsSet(void) const
Check if a value has been assigned to data member.
void SetBiomol(TBiomol value)
Assign a value to Biomol data member.
EMol
molecule class in living organism
bool IsPub(void) const
Check if variant Pub is selected.
void SetDescr(TDescr &value)
Assign a value to Descr data member.
const TDelta & GetDelta(void) const
Get the variant data.
TSeg & SetSeg(void)
Select the variant.
void ResetLinkage_evidence(void)
Reset Linkage_evidence data member.
const TNcbi4na & GetNcbi4na(void) const
Get the variant data.
TUser & SetUser(void)
Select the variant.
void SetRepr(TRepr value)
Assign a value to Repr data member.
const TNcbi2na & GetNcbi2na(void) const
Get the variant data.
const Tdata & Get(void) const
Get the member data.
E_Choice Which(void) const
Which variant is currently selected.
bool CanGetExt(void) const
Check if it is safe to call GetExt method.
bool IsSetId(void) const
equivalent identifiers Check if a value has been assigned to Id data member.
Tdata & Set(void)
Assign a value to data member.
void SetLength(TLength value)
Assign a value to Length data member.
list< CRef< CDelta_seq > > Tdata
const Tdata & Get(void) const
Get the member data.
void SetLinkage(TLinkage value)
Assign a value to Linkage data member.
void SetSeq_data(TSeq_data &value)
Assign a value to Seq_data data member.
void ResetExt(void)
Reset Ext data member.
const TPub & GetPub(void) const
Get the Pub member data.
const TSeq_data & GetSeq_data(void) const
Get the Seq_data member data.
list< CRef< CSeq_loc > > Tdata
const TNcbi8na & GetNcbi8na(void) const
Get the variant data.
const TDescr & GetDescr(void) const
Get the Descr member data.
void Reset(void)
Reset data member.
TMolinfo & SetMolinfo(void)
Select the variant.
void ResetSeq_data(void)
Reset Seq_data data member.
E_Choice Which(void) const
Which variant is currently selected.
@ eRepr_seg
segmented sequence
@ eRepr_delta
sequence made by changes (delta) to others
@ eRepr_raw
continuous sequence
@ eCompleteness_complete
complete biological entity
@ eCompleteness_no_left
missing 5' or NH3 end
@ eCompleteness_no_right
missing 3' or COOH end
@ eCompleteness_no_ends
missing both ends
@ e_Ncbi2na
2 bit nucleic acid code
@ e_Iupacna
IUPAC 1 letter nuc acid code.
@ e_Ncbi8na
8 bit extended nucleic acid code
@ e_Ncbi4na
4 bit nucleic acid code
@ e_Embl
EMBL specific information.
@ e_Het
cofactor, etc associated but not bound
@ e_Org
if all from one organism
@ e_Num
a numbering system
@ e_User
user defined object
@ e_Update_date
date of last update
@ e_Pub
a reference to the publication
@ e_Pir
PIR specific info.
@ e_Genbank
GenBank specific info.
@ e_Prf
PRF specific information.
@ e_Mol_type
type of molecule
@ e_Sp
SWISSPROT specific info.
@ e_Dbxref
xref to other databases
@ e_Comment
a more extensive comment
@ e_Method
sequencing method
@ e_Modelev
model evidence for XM records
@ e_Region
overall region (globin locus)
@ e_Molinfo
info on the molecule and techniques
@ e_Maploc
map location of this sequence
@ e_Create_date
date entry first created/released
@ e_Title
a title for this sequence
@ e_Pdb
PDB specific information.
@ e_not_set
No variant selected.
@ e_Name
a name for this sequence
@ e_Source
source of materials, includes Org-ref
const TCit & GetCit(void) const
Get the Cit member data.
list< CRef< CSeq_entry > > TEntrys
const TEntrys & GetEntrys(void) const
Get the variant data.
const TData & GetData(void) const
Get the Data member data.
const TSub & GetSub(void) const
Get the Sub member data.
bool IsSetSub(void) const
Check if a value has been assigned to Sub data member.
bool IsSetCit(void) const
citation for this submission Check if a value has been assigned to Cit data member.
void FeatureAdjustForInsert(CSeq_feat &feat, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
void FeatureAdjustForTrim(CSeq_feat &feat, TSeqPos from, TSeqPos to, const CSeq_id *seqid, bool &bCompleteCut, bool &bAdjusted)
vector< CRef< objects::CSeq_align > > TAlignVec
range(_Ty, _Ty) -> range< _Ty >
constexpr auto make_array(T &&a)
constexpr auto sort(_Init &&init)
double value_type
The numeric datatype used by the parser.
const struct ncbi::grid::netcache::search::fields::SIZE size
Int4 delta(size_t dimension_, const Int4 *score_)
double r(size_t dimension_, const Int4 *score_, const double *prob_, double theta_)
void copy(Njn::Matrix< S > *matrix_, const Njn::Matrix< T > &matrix0_)
double f(double x_, const double &y_)
static const char * expected[]
static void s_AdjustInternalCutLocations(TCuts &cuts, TSeqPos seq_length, EInternalTrimType internal_cut_conversion)
Adjust any internal cuts to terminal cuts.
void TrimSeqAlign(CBioseq_Handle bsh, CRef< CSeq_align > align, const TCuts &sorted_cuts)
Trim Seq-align annotation.
void SetLinkageType(CSeq_ext &ext, CSeq_gap::TType linkage_type)
SetLinkageType A function to set the linkage_type for gaps in a delta sequence.
void DivvyUpAlignments(const TVecOfSeqEntryHandles &vecOfSeqEntryHandles)
Call this if the alignments directly under these seq-entries are all jumbled up between each other.
static CSeq_id * s_MakeUniqueLocalId(void)
vector< CSeq_annot_Handle > TVecOfSeqAnnotsToErase
void AddBioseqToBioseq(const CBioseq_Handle &to, const CBioseq_Handle &add)
Attach one Bioseq to another.
bool HasRepairedIDs(const CUser_object &user, const CBioseq::TId &ids)
bool IsDeltaSeqGap(CConstRef< CDelta_seq > delta)
string MakeOriginalLabelForId(const CSeq_id &id)
void TrimSeqData(CBioseq_Handle bsh, CRef< CSeq_inst > inst, const TCuts &sorted_cuts)
Trim sequence data.
void s_AddLiteral(CSeq_inst &inst, const string &element)
CRef< CSeqdesc > FindUnverified(const CBioseq &seq)
static void s_AddBioseqToBioseq(const CBioseq_EditHandle &to, const CBioseq_EditHandle &add)
void ConvertRawToDeltaByNs(CSeq_inst &inst, size_t min_unknown, int max_unknown, size_t min_known, int max_known, bool is_assembly_gap, int gap_type, int linkage, int linkage_evidence)
ConvertRawToDeltaByNs A function to convert a raw sequence to a delta sequence, using runs of Ns to d...
static void s_AddBioseqToSegset(CBioseq_set_EditHandle &segset, CBioseq_EditHandle &part)
static bool s_DivvyUpAlignments_ProcessAnnot_Dendiag(const CSeq_align_Handle &align, const TMapDescendentToInputEntry &mapDescendentToInputEntry, TMapEntryToAlignVec &mapEntryToAlignVec)
static void s_AddBioseqToNucProtSet(CBioseq_set_EditHandle &nuc_prot, CBioseq_EditHandle &seq)
CMapWithOriginalOrderingIteration< CSeq_entry_Handle, TAlignVec > TMapEntryToAlignVec
void TrimSeqGraph(CBioseq_Handle bsh, CRef< CSeq_graph > graph, const TCuts &sorted_cuts)
Trim Seq-graph annotation.
void GetSortedCuts(CBioseq_Handle bsh, const TCuts &cuts, TCuts &sorted_cuts, EInternalTrimType internal_cut_conversion)
1) Adjust any internal cuts to terminal cuts according to option.
bool Does3primerAbutGap(const CSeq_feat &feat, CBioseq_Handle seq_hl)
void SetTargetedLocusName(CBioseq_Handle seq, const string &tls)
void SortSeqDescr(CSeq_descr &descr)
vector< CConstRef< CSeq_align > > TAlignVec
bool IsUnverifiedMisassembled(const CBioseq &seq)
void AddSeqdescToSeqDescr(const CSeqdesc &desc, CSeq_descr &seq_descr)
static void s_AddBioseqToPartsSet(CBioseq_set_EditHandle &parts, CBioseq_EditHandle &seq)
void AddSeqEntryToSeqEntry(const CSeq_entry_Handle &target, const CSeq_entry_Handle &insert)
Attach one Seq-entry to another.
void AddSeqdescToBioseq(const CSeqdesc &desc, CBioseq &seq)
void AddLocalIdUserObjects(CSeq_entry &entry)
Creates a User-object descriptor on every sequence that has a local ID Contains the original local ID...
CRef< CSeq_entry > SeqEntryFromSeqSubmit(const CSeq_submit &submit)
Create a Seq-entry from a Seq-submit.
void s_AddGap(CSeq_inst &inst, size_t n_len, bool is_unknown, bool is_assembly_gap=false, int gap_type=CSeq_gap::eType_unknown, int linkage=-1, int linkage_evidence=-1)
void ResetLinkageEvidence(CSeq_ext &ext)
ResetLinkageEvidence A function to clear linkage evidence for gaps in a delta sequence.
map< CSeq_entry_Handle, CSeq_entry_Handle > TMapDescendentToInputEntry
bool s_FindSegment(const CDense_seg &denseg, CDense_seg::TDim row, TSeqPos pos, CDense_seg::TNumseg &seg, TSeqPos &seg_start)
CConstRef< CDelta_seq > GetDeltaSeqForPosition(const unsigned pos, const CBioseq_Handle seq_hl, CScope *scope, unsigned &left_endpoint)
void s_BasicValidation(CBioseq_Handle bsh, const TCuts &cuts)
bool IsSeqDescInList(const CSeqdesc &desc, const CSeq_descr &set)
static bool s_DivvyUpAlignments_ProcessAnnot_Denseg(const CSeq_align_Handle &align, const TMapDescendentToInputEntry &mapDescendentToInputEntry, TMapEntryToAlignVec &mapEntryToAlignVec)
void RemoveUserObjectType(CSeq_entry &entry, CUser_object::EObjectType type)
Removes User-object descriptors of a certain type from the seq-entry.
void TrimSequenceAndAnnotation(CBioseq_Handle bsh, const TCuts &cuts, EInternalTrimType internal_cut_conversion)
Implementation detail: first trim all associated annotation, then trim sequence data.
bool IsUnverifiedOrganism(const CBioseq &seq)
static void s_DivvyUpAlignments_ProcessAnnot(const CSeq_annot_Handle &annot_h, const TMapDescendentToInputEntry &mapDescendentToInputEntry, TMapSeqAnnotToDest &mapSeqAnnotToDest, TVecOfSeqAnnotsToErase &vecOfSeqAnnotToErase)
static void s_UpdateSeqGraphLoc(CRef< CSeq_graph > graph, const TCuts &sorted_cuts)
CRef< CBioseq > SetNewProteinSequence(CScope &new_scope, CRef< CSeq_feat > cds, CRef< CSeq_inst > new_inst)
Secondary function needed after trimming Seq-feat.
void SetLinkageTypeScaffold(CSeq_ext &ext, CLinkage_evidence::TType evidence_type)
SetLinkageTypeScaffold A special case of SetLinkageType.
static void s_SeqLocDelete(CRef< CSeq_loc > loc, TSeqPos from, TSeqPos to, bool &bCompleteCut, bool &bTrimmed)
void SetLinkageTypeLinkedRepeat(CSeq_ext &ext, CLinkage_evidence::TType evidence_type)
CSeq_id::E_Choice TypeFromLabel(const string &label)
void DeleteProteinAndRenormalizeNucProtSet(const CSeq_feat_Handle &feat_h)
Secondary function needed after trimming Seq-feat.
bool Does5primerAbutGap(const CSeq_feat &feat, CBioseq_Handle seq_hl)
static void s_MakeGroupsForUniqueValues(const CSeq_entry_Handle &target, const CScope::TBioseqHandles &bioseq_handles)
void SegregateSetsByBioseqList(const CSeq_entry_Handle &target, const CScope::TBioseqHandles &bioseq_handles)
Split a Seq-entry, where the second part holds the given bioseqs.
string GetTargetedLocusNameConsensus(const string &tls1, const string &tls2)
CMapWithOriginalOrderingIteration< CRef< CSeq_annot >, CSeq_entry_Handle > TMapSeqAnnotToDest
void SetPartial(CSeq_loc &loc, CRef< CSeq_feat > feat, CSeq_loc::TStrand strand, bool partial_start, bool partial_stop)
void TrimSeqFeat(CRef< CSeq_feat > feat, const TCuts &sorted_cuts, bool &bFeatureDeleted, bool &bFeatureTrimmed, bool &partial_start, bool &partial_stop)
Trim Seq-feat annotation.
static void s_AddProtToNuc(const CBioseq_EditHandle &nuc, const CBioseq_EditHandle &prot)
void RetranslateCdregion(CBioseq_Handle nuc_bsh, bool isPartialStart, bool isPartialStop, CRef< CSeq_inst > trimmed_nuc_inst, CRef< CSeq_feat > cds, const TCuts &sorted_cuts)
Secondary function needed after trimming Seq-feat.
static void s_SeqIntervalDelete(CRef< CSeq_interval > interval, TSeqPos cut_from, TSeqPos cut_to, bool &bCompleteCut, bool &bTrimmed)
const string & GetTargetedLocusName(const CGene_ref &gene)
bool IsUnverifiedContaminant(const CBioseq &seq)
bool IsUnverifiedFeature(const CBioseq &seq)
void s_CutDensegSegment(CRef< CSeq_align > align, CDense_seg::TDim row, TSeqPos pos)
void BioseqSetDescriptorPropagateDown(const CBioseq_set_Handle &bioseq_set_h, const vector< CSeqdesc::E_Choice > &choices_to_delete)
Moves descriptors down to children of the given bioseq-set.
TLocAdjustmentVector NormalizeUnknownLengthGaps(CSeq_inst &inst, TSeqPos unknown_length)
NormalizeUnknownLengthGaps A function to adjust the length of unknown-length gaps to a specific lengt...
void AdjustCdregionFrame(TSeqPos original_nuc_len, CRef< CSeq_feat > cds, const TCuts &sorted_cuts)
Secondary function needed after trimming Seq-feat.
static void s_AddPartToSegmentedBioseq(const CBioseq_EditHandle &seg, const CBioseq_EditHandle &part)
static TRange s_GetRetainedRange(const TCuts &sorted_merged_cuts, TSeqPos seqLength)
void AddLinkageEvidence(CSeq_ext &ext, CLinkage_evidence::TType evidence_type)
AddLinkageEvidence A function to add linkage evidence for gaps in a delta sequence.
static void s_PromoteSingletonSetsInSet(const CBioseq_set_Handle &bioseq_set_h)
CRef< CUser_field > MakeOriginalIdField(const CSeq_id &id)
void AddBioseqToBioseqSet(const CBioseq_set_Handle &set, const CBioseq_Handle &seq)
Add a Bioseq to a Bioseq-set.
static bool s_IsSingletonSet(const CBioseq_set_Handle &bioseq_set)
string GenerateTargetedLocusName(CBioseq_Handle seq)
void AddSeqdescToBioseqSet(const CSeqdesc &desc, CBioseq_set &set)
bool AddSeqdescToSeqEntryRecursively(CSeq_entry &entry, CSeqdesc &desc)
void UpdateSeqLength(CAutoInitRef< CDelta_ext > &pDeltaExt, CBioseq_Handle &complete_bsh, CSeqMap_CI &seqmap_ci, CSeq_inst_Base::TLength &new_length)
Update sequence length.
static void s_MergeCuts(TCuts &sorted_cuts)
Assumes sorted_cuts are sorted in Ascending order!
bool IsMatchingIdMissing(const CUser_field &field, const CBioseq::TId &ids)
string LabelFromType(CSeq_id::E_Choice choice)
void BioseqSetDescriptorPropagateUp(CBioseq_set_Handle set)
Moves descriptors up from children of the given bioseq-set if each child has an identical copy of the...
void HandleCollidingIds(CSeq_entry &entry)
static void s_GetTrimCoordinates(CBioseq_Handle bsh, const TCuts &sorted_cuts, TSeqPos &trim_start, TSeqPos &trim_stop)
vector< TLocAdjustment > TLocAdjustmentVector
vector< CSeq_entry_Handle > TVecOfSeqEntryHandles
EInternalTrimType
Any internal cut listed in TCuts will be converted to a terminal cut using one of these options.
pair< TSeqPos, int > TLocAdjustment
#define ERASE_SEQDESC_ON_BIOSEQ(Itr, Var)
ERASE_SEQDESC_ON_BIOSEQ.
#define EDIT_EACH_SEQDESC_ON_BIOSEQ(Itr, Var)
#define EDIT_EACH_SEQDESC_ON_SEQSET(Itr, Var)
#define ERASE_SEQDESC_ON_SEQSET(Itr, Var)
ERASE_SEQDESC_ON_SEQSET.
#define FIELD_EQUALS(Var, Fld, Value)
FIELD_EQUALS base macro.
#define RAW_FIELD_IS_EMPTY(Var, Fld)
RAW_FIELD_IS_EMPTY base macro.
set< CConstRef< T >, SSerialObjectLessThan< T > > Type
map< CConstRef< T >, string > TMapObjToTextAsn
TMapObjToTextAsn m_ObjAsnCache
bool operator()(const CConstRef< T > &lhs, const CConstRef< T > &rhs) const
const string & x_GetAsnText(const CConstRef< T > &obj) const