best_id = sid.AsFastaString();
101from = seq_int.
GetTo();
104f_from.
GetLabel(&lab_from, from,
false);
114to = seq_int.
GetTo();
118f_from.
GetLabel(&lab_from, from,
false);
127 location+= lab_from +
"-"+ lab_to;
137 if(seq_loc.
IsPnt()) {
156 if(seq_loc.
IsInt()) {
161 constlist <CRef <CSeq_loc> >* seq_loc_ls;
162 if(seq_loc.
IsMix()) {
163seq_loc_ls = &(seq_loc.
GetMix().
Get());
169 if(it == seq_loc.
GetMix().
Get().begin()) {
199 else if(seq_loc.
IsBond()) {
278 size_tnum_intervals = last_l.
GetSize();
279last_l.
SetPos(num_intervals - 1);
303 bool& do_set_5_partial,
304 bool& do_clear_5_partial)
const 306do_set_5_partial =
false;
307do_clear_5_partial =
false;
316do_set_5_partial =
true;
318 boolconfident =
false;
320 if(confident && !at_5) {
321do_set_5_partial =
true;
327 boolconfident =
false;
329do_set_5_partial =
true;
337 boolconfident =
true;
347do_set_5_partial =
true;
357do_set_5_partial =
true;
362do_clear_5_partial =
true;
367 boolconfident =
false;
369do_clear_5_partial =
true;
380 boolconfident =
true;
390do_clear_5_partial =
true;
395 returndo_set_5_partial || do_clear_5_partial;
402 bool& do_set_3_partial,
403 bool& do_clear_3_partial)
const 405do_set_3_partial =
false;
406do_clear_3_partial =
false;
415do_set_3_partial =
true;
417 boolconfident =
false;
419 if(confident && !at_3) {
420do_set_3_partial =
true;
426 boolconfident =
false;
428 if(at_3 && confident) {
429do_set_3_partial =
true;
437 boolconfident =
true;
447do_set_3_partial =
true;
456do_clear_3_partial =
true;
461 boolconfident =
false;
463 if(!at_3 && confident) {
464do_clear_3_partial =
true;
472 boolconfident =
true;
482do_clear_3_partial =
true;
487 returndo_set_3_partial || do_clear_3_partial;
520 size_tnum_intervals = last_l.
GetSize();
521last_l.
SetPos(num_intervals - 1);
555 if(pos < loc_start) {
557 id->Assign(*(loc.
GetId()));
559 new CSeq_loc(*
id,
static_cast<TSeqPos>(pos), loc_start - 1, strand));
563}
else if(pos > loc_stop) {
565 id->Assign(*(loc.
GetId()));
567*
id, loc_stop + 1,
static_cast<TSeqPos>(pos), strand));
584 boolany_change =
false;
587 booldo_set_5_partial =
false;
588 booldo_clear_5_partial =
false;
589any_change |=
Interpret5Policy(feat, scope, do_set_5_partial, do_clear_5_partial);
590 if(do_set_5_partial) {
596}
else if(do_clear_5_partial) {
601 booldo_set_3_partial =
false;
602 booldo_clear_3_partial =
false;
603any_change |=
Interpret3Policy(feat, scope, do_set_3_partial, do_clear_3_partial);
604 if(do_set_3_partial) {
610}
else if(do_clear_3_partial) {
619 boolchanged =
false;
630 boolchanged =
false;
661 if((*it)->IsNull()) {
675new_loc->
Assign(orig_loc);
681 if(subloc && !subloc->
IsNull()) {
684new_loc->
SetMix().Set().push_back(add);
699new_loc->
Assign(orig_loc);
702 switch(orig_loc.
Which()) {
712new_loc->
Assign(orig_loc);
727new_loc->
SetMix().Set().push_back(null_loc);
730new_loc->
SetMix().Set().push_back(add);
754 switch((orig_frame + diff % 3) % 3) {
765feat.
SetData().SetCdregion().SetFrame(new_frame);
772 boolextend =
false;
774 boolconfident =
false;
807 boolextend =
false;
809 boolconfident =
false;
812 size_tnum_intervals = last_l.
GetSize();
813last_l.
SetPos(num_intervals - 1);
836 CScope& scope,
booladjust_gene,
boolretranslate_cds)
839new_feat->
Assign(orig_feat);
856new_gene->
Assign(*old_gene);
857 boolgene_change =
false;
915interval.
SetTo(from);
916}
else if(interval.
IsSetTo()) {
977vector<int> new_pnts;
982 ITERATE(vector<int>, it, new_pnts) {
993 switch(loc.
Which()) {
1052 if((*it)->IsSetLoc()) {
1126 switch(loc.
Which()) {
1129CSeq_loc::TEquiv::Tdata::iterator it = loc.
SetEquiv().Set().begin();
1130 while(it != loc.
SetEquiv().Set().end()) {
1133it = loc.
SetEquiv().Set().erase(it);
1144}
else if(loc.
GetEquiv().
Get().size() == 0) {
1152CSeq_loc::TMix::Tdata::iterator it = loc.
SetMix().Set().begin();
1153 while(it != loc.
SetMix().Set().end()) {
1156it = loc.
SetMix().Set().erase(it);
1163 if(loc.
GetMix().
Get().size() == 1) {
1167}
else if(loc.
GetMix().
Get().size() == 0) {
1179loc.
SetInt().Assign(*sub);
1197loc.
SetPnt().Assign(*sub);
1210 bool& bCompleteCut,
1229 TSeqPoscut_size = cut_to - cut_from + 1;
1232 if(feat_to < cut_from)
1239 if(feat_from >= cut_from && feat_to <= cut_to)
1242bCompleteCut =
true;
1243trim5 += feat_from - feat_to + 1;
1248 if(feat_from > cut_to)
1251feat_from -= cut_size;
1252feat_to -= cut_size;
1253interval.
SetFrom(feat_from);
1254interval.
SetTo(feat_to);
1269 if(feat_to > cut_to) {
1271feat_to -= cut_size;
1276 TSeqPosdiff = cut_from - 1 - feat_to;
1279feat_to = cut_from - 1;
1283 if(feat_from >= cut_from) {
1285 TSeqPosdiff = cut_to + 1 - feat_from;
1288feat_from = cut_to + 1;
1289feat_from -= cut_size;
1292interval.
SetFrom(feat_from);
1293interval.
SetTo(feat_to);
1301 bool& bCompleteCut,
1305 if(packint.
IsSet()) {
1308CPacked_seqint::Tdata::iterator it;
1309 for(it = packint.
Set().begin();
1310it != packint.
Set().end(); )
1312 boolbDeleted =
false;
1315bDeleted, this_trim, bAdjusted);
1322it = packint.
Set().erase(it);
1329 if(packint.
Get().empty()) {
1333 if(!packint.
IsSet()) {
1334bCompleteCut =
true;
1342 bool& bCompleteCut,
1346 if(mix.
IsSet()) {
1349CSeq_loc_mix::Tdata::iterator it;
1350 for(it = mix.
Set().begin();
1351it != mix.
Set().end(); )
1353 boolbDeleted =
false;
1362it = mix.
Set().erase(it);
1370 if(!mix.
IsSet() || mix.
Set().empty()) {
1371bCompleteCut =
true;
1379 bool& bCompleteCut,
1388 autodiff = to - from + 1;
1391}
else if(from < pnt.
GetPoint()) {
1392bCompleteCut =
true;
1401 bool& bCompleteCut,
TSeqPos& trim5,
bool& bAdjusted)
1407 if(
pack.IsSetPoints()) {
1409 autoit =
pack.SetPoints().begin();
1410 while(it !=
pack.SetPoints().end()) {
1412 autodiff = to - from + 1;
1417}
else if(from < *it) {
1418it =
pack.SetPoints().erase(it);
1429 if(
pack.SetPoints().empty()) {
1430bCompleteCut =
true;
1438 bool& bCompleteCut,
1442 boolcutA =
false, cutB =
false;
1455bCompleteCut =
true;
1463 bool& bCompleteCut,
1468CSeq_loc_equiv::Tdata::iterator it = equiv.
Set().begin();
1469 while(it != equiv.
Set().end()) {
1473 if(this_trim5 > max_trim5) {
1474max_trim5 = this_trim5;
1477it = equiv.
Set().erase(it);
1482 if(equiv.
Set().empty()) {
1483bCompleteCut =
true;
1492 bool& bCompleteCut,
1493 TSeqPos& trim5,
bool& bAdjusted)
1497 switch(loc.
Which())
1502bCompleteCut, trim5, bAdjusted);
1534 if(!bCompleteCut) {
1559 TSeqPosinsert_size = insert_to - insert_from + 1;
1562 if(feat_to < insert_from)
1569 if(feat_from > insert_from) {
1570feat_from += insert_size;
1571feat_to += insert_size;
1572interval.
SetFrom(feat_from);
1573interval.
SetTo(feat_to);
1578 if(feat_from <= insert_from && feat_to >= insert_from)
1580feat_to += insert_size;
1581interval.
SetTo(feat_to);
1591 if(packint.
IsSet()) {
1593CPacked_seqint::Tdata::iterator it;
1594 for(it = packint.
Set().begin();
1595it != packint.
Set().end(); it++)
1607 if(mix.
IsSet()) {
1609CSeq_loc_mix::Tdata::iterator it;
1610 for(it = mix.
Set().begin();
1611it != mix.
Set().end(); it++)
1630 if(insert_from < pnt.
GetPoint()) {
1631 autodiff = insert_to - insert_from + 1;
1645 autoit = packpnt.
SetPoints().begin();
1646 while(it != packpnt.
SetPoints().end()) {
1648 autodiff = to - from + 1;
1674CSeq_loc_equiv::Tdata::iterator it = equiv.
Set().begin();
1675 while(it != equiv.
Set().end()) {
1688 switch(loc.
Which())
1730 const CSeq_id* seqid,
bool& cut,
1731 unsigned intoptions)
1747 if(feat_to < start) {
1758 if(feat_from < start && feat_to > stop) {
1765 if(feat_to > stop) {
1768 if(stop + 1 > feat_from) {
1775 if(feat_from < start) {
1776before.
SetTo(start - 1);
1790 const CSeq_id* seqid,
unsigned intoptions)
1792 if(before_intervals.
IsSet()) {
1794reverse(before_intervals.
Set().begin(), before_intervals.
Set().end());
1797 autoit = before_intervals.
Set().begin();
1798 while(it != before_intervals.
Set().end()) {
1802 if(int_from > stop && after_intervals.
IsSet() && !after_intervals.
Get().empty()) {
1803after_intervals.
Set().push_back(
Ref(&sub_interval));
1804it = before_intervals.
Set().erase(it);
1812it = before_intervals.
Set().erase(it);
1818after_intervals.
Set().push_back(after);
1824reverse(after_intervals.
Set().begin(), after_intervals.
Set().end());
1827reverse(before_intervals.
Set().begin(), before_intervals.
Set().end());
1834 size_tstart,
size_tstop,
1835 const CSeq_id* seqid,
unsigned intoptions)
1840 switch(loc1.
Which())
1848seqid, cut, options);
1886 if(before_intervals.
Set().empty()) {
1889 if(!after_intervals->Set().empty()) {
1906 if(before_mix.
IsSet()) {
1908reverse(before_mix.
Set().begin(), before_mix.
Set().end());
1910 autoit = before_mix.
Set().begin();
1911 while(it != before_mix.
Set().end()) {
1915 if(from > stop && after_mix->IsSet() && !after_mix->Get().empty()) {
1916after_mix->Set().push_back(
Ref(&sub_loc));
1917it = before_mix.
Set().erase(it);
1924it = before_mix.
Set().erase(it);
1930after_mix->Set().push_back(after);
1935 if(after_mix->IsReverseStrand()) {
1936reverse(after_mix->Set().begin(), after_mix->Set().end());
1939reverse(before_mix.
Set().begin(), before_mix.
Set().end());
1943 if(before_mix.
Set().empty()) {
1946 if(!after_mix->Set().empty()) {
1948loc2.
SetMix().Assign(*after_mix);
1952add->
SetMix().Assign(*after_mix);
1963 if(before_equiv.
IsSet()) {
1965CSeq_loc_equiv::Tdata::iterator it;
1966 for(it = before_equiv.
Set().begin();
1967it != before_equiv.
Set().end(); )
1973it = before_equiv.
Set().erase(it);
1979after_equiv->Set().push_back(after);
1984 if(before_equiv.
Set().empty()) {
1987 if(!after_equiv->Set().empty()) {
1989loc2.
SetMix().Assign(*after_equiv);
1992add->
SetMix().Assign(*after_equiv);
2003CPacked_seqpnt::TPoints::iterator it = loc1.
SetPacked_pnt().SetPoints().begin();
2006after_points.push_back(*it);
2009it = before_points.erase(it);
2014 if(!after_points.empty()) {
2017after->SetPoints().assign(after_points.begin(), after_points.end());
2026 if(before_points.empty()) {
2049CCdregion::TCode_break::iterator it = cdr.
SetCode_break().begin();
2051 if((*it)->IsSetLoc()) {
2053 booladjusted =
false;
2077 booltrimmed =
false;
2090 bool& bCompleteCut,
2118CCdregion::TCode_break::iterator it = cdr.
SetCode_break().begin();
2120 if((*it)->IsSetLoc()) {
2212 if(pint.
Get().size() < 2) {
2215 boolany_change =
false;
2217 boolthis_change =
true;
2218 while(this_change) {
2219this_change =
false;
2222CPacked_seqint::Tdata::iterator
a= pint.
Set().begin();
2223CPacked_seqint::Tdata::iterator
b=
a;
2225 while(
b!= pint.
Set().end()) {
2226 if((*a)->IsSetId() && (*b)->IsSetId() &&
2227(*a)->GetId().Equals((*b)->GetId()) &&
2228(*a)->IsSetFrom() && (*a)->IsSetTo() && (*a)->GetFrom() < (*a)->GetTo() &&
2229(*b)->IsSetFrom() && (*b)->IsSetTo() && (*b)->GetFrom() < (*b)->GetTo() &&
2232 if((*b)->GetTo() > (*a)->GetFrom()) {
2234 a->Reset(
b->GetPointer());
2236this_change =
true;
2240 if((*b)->GetTo() < (*a)->GetFrom()) {
2242 a->Reset(
b->GetPointer());
2244this_change =
true;
2278 if(this_strand != strand) {
2292 boolany_change =
false;
2296 if(mix.size() < 2) {
2299 boolthis_change =
true;
2300 while(this_change) {
2301this_change =
false;
2304CSeq_loc::TMix::Tdata::iterator
a= mix.begin();
2305CSeq_loc::TMix::Tdata::iterator
b=
a;
2307 while(
b!= mix.end()) {
2316a_strand == b_strand) {
2320 a->Reset(
b->GetPointer());
2322this_change =
true;
2328 a->Reset(
b->GetPointer());
2330this_change =
true;
2348 boolany_change =
false;
2349 switch(loc.
Which()) {
2388 if((*it)->IsLiteral()) {
2389 offset+= (*it)->GetLiteral().GetLength();
2390 if(!(*it)->GetLiteral().IsSetSeq_data()) {
2392}
else if((*it)->GetLiteral().GetSeq_data().IsGap()) {
2395}
else if((*it)->IsLoc()) {
2402 if(left >= last_gap_stop && left - last_gap_stop <= 3) {
2404extend_len = left - last_gap_stop;
2416extend_len = seq.
GetLength() - right - 1;
2424 if((*it)->IsLiteral()) {
2425 if(!(*it)->GetLiteral().IsSetSeq_data()) {
2426next_gap_start =
offset;
2427}
else if((*it)->GetLiteral().GetSeq_data().IsGap()) {
2428next_gap_start =
offset;
2430 offset+= (*it)->GetLiteral().GetLength();
2431}
else if((*it)->IsLoc()) {
2434 if(
offset> right + 4) {
2438 if(next_gap_start > right && next_gap_start - right - 1 <= 3) {
2440extend_len = next_gap_start - right - 1;
2462 boolextendable =
false;
2468new_start = start - extend_len;
2471 if(start < seq->GetInst().
GetLength() - 1) {
2473new_start = start + extend_len;
2479 for(
autoit : related_features) {
2483it->SetLocation().Assign(*related_loc);
2484 if(it->IsSetData() && it->GetData().IsCdregion()) {
2512 size_tnum_intervals = last_l.
GetSize();
2513last_l.
SetPos(num_intervals - 1);
2521 boolextendable =
false;
2525 if(stop < seq->GetInst().
GetLength() - 1) {
2527new_stop = stop + extend_len;
2532new_stop = stop - extend_len;
2538 for(
autoit : related_features) {
2542it->SetLocation().Assign(*related_loc);
2563 if(
IsExtendableLeft(start, *seq, &scope, extend_len) && extend_len > 0) {
2569 size_tnum_intervals = last_l.
GetSize();
2570last_l.
SetPos(num_intervals - 1);
2587 boolany_change =
false;
2591 if(
f->GetData().IsCdregion()) {
2594vector<CRef<CSeq_feat> > related_features;
2598related_features.push_back(new_gene);
2603related_features.push_back(new_mRNA);
2606new_cds->
Assign(*(
f->GetOriginalSeq_feat()));
2611 if(adjusted_5prime || adjusted_3prime) {
2617geh.
Replace(*(related_features.front()));
2621meh.
Replace(*(related_features.back()));
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
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.
User-defined methods of the data storage class.
TSeqPos GetLength(void) const
void GetLabel(string *label, TSeqPos pos, bool right=true) const
static CRef< CSeq_loc > ConvertToOrder(const CSeq_loc &orig_loc, bool &changed)
bool Interpret5Policy(const CSeq_feat &orig_feat, CScope &scope, bool &do_set_5_partial, bool &do_clear_5_partial) const
@ eMergePolicy_SingleInterval
static bool HasNulls(const CSeq_loc &orig_loc)
static bool Extend3(CSeq_feat &feat, CScope &scope)
static bool Extend5(CSeq_feat &feat, CScope &scope)
static CRef< CSeq_loc > ConvertToJoin(const CSeq_loc &orig_loc, bool &changed)
EPartialPolicy m_PartialPolicy3
static bool Is3AtEndOfSeq(const CSeq_loc &loc, CBioseq_Handle bsh)
static bool Is5AtEndOfSeq(const CSeq_loc &loc, CBioseq_Handle bsh)
EPartialPolicy m_PartialPolicy5
@ ePartialPolicy_eSetForFrame
@ ePartialPolicy_eSetAtEnd
@ ePartialPolicy_eNoChange
@ ePartialPolicy_eSetForBadEnd
@ ePartialPolicy_eClearForGoodEnd
@ ePartialPolicy_eClearNotAtEnd
EMergePolicy m_MergePolicy
bool Interpret3Policy(const CSeq_feat &orig_feat, CScope &scope, bool &do_set_3_partial, bool &do_clear_3_partial) const
bool ApplyPolicyToFeature(CSeq_feat &feat, CScope &scope) const
bool IsReverseStrand(void) const
ESubtype GetSubtype(void) const
CSeq_feat_EditHandle â.
namespace ncbi::objects::
Seq-loc iterator class â iterates all intervals from a seq-loc in the correct order.
bool IsReverseStrand(void) const
Include a standard set of the NCBI C++ Toolkit most basic headers.
static DLIST_TYPE *DLIST_NAME() first(DLIST_LIST_TYPE *list)
static const char * pack(const char *fmt,...)
static const char location[]
unsigned int TSeqPos
Type for sequence locations and lengths.
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#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)
virtual void Assign(const CSerialObject &source, ESerialRecursionMode how=eRecursive)
Set object to copy of another one.
virtual bool Equals(const CSerialObject &object, ESerialRecursionMode how=eRecursive) const
Check if both objects contain the same values.
const string AsFastaString(void) const
CConstRef< CSeq_id > GetSeqId(void) const
E_SIC Compare(const CSeq_id &sid2) const
Compare() - more general.
@ e_YES
SeqIds compared, but are different.
void SetPacked_int(TPacked_int &v)
void InvalidateCache(void) const
Combine invalidation of all cached values.
void SetPacked_pnt(TPacked_pnt &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.
virtual void Assign(const CSerialObject &source, ESerialRecursionMode how=eRecursive)
Override Assign() to incorporate cache invalidation.
TSeqPos GetStart(ESeqLocExtremes ext) const
Return start and stop positions of the seq-loc.
CConstRef< CSeq_loc > GetRangeAsSeq_loc(void) const
Get seq-loc for the current iterator position.
bool IsSetStrand(void) const
Get strand.
void Add(const CSeq_loc &other)
Simple adding of seq-locs.
bool IsSetStrand(EIsSetStrand flag=eIsSetStrand_Any) const
Check if strand is set for any/all part(s) of the seq-loc depending on the flag.
void SetPos(size_t pos)
Set iterator's position.
const CSeq_id * GetId(void) const
Get the id of the location return NULL if has multiple ids or no id at all.
size_t GetSize(void) const
Get number of ranges.
TRange GetRange(void) const
Get the range.
void SetPartialStart(bool val, ESeqLocExtremes ext)
set / remove e_Lim fuzz on start or stop (lt/gt - indicating partial interval)
ENa_strand GetStrand(void) const
const CSeq_id & GetSeq_id(void) const
Get seq_id of the current location.
void GetLabel(string *label) const
Appends a label suitable for display (e.g., error messages) label must point to an existing string ob...
void SetPartialStop(bool val, ESeqLocExtremes ext)
void SetNull(void)
Override all setters to incorporate cache invalidation.
bool IsPartialStop(ESeqLocExtremes ext) const
TSeqPos GetStop(ESeqLocExtremes ext) const
bool RetranslateCDS(const CSeq_feat &cds, CScope &scope)
RetranslateCDS A function to replace the protein Bioseq pointed to by cds.product with the current tr...
bool AdjustFeaturePartialFlagForLocation(CSeq_feat &new_feat)
AdjustFeaturePartialFlagForLocation A function to ensure that Seq-feat.partial is set if either end o...
bool AdjustForCDSPartials(const CSeq_feat &cds, CSeq_entry_Handle seh)
AdjustForCDSPartials A function to make all of the necessary related changes to a Seq-entry after the...
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.
sequence::ECompare Compare(const CSeq_loc &loc1, const CSeq_loc &loc2, CScope *scope)
Returns the sequence::ECompare containment relationship between CSeq_locs.
CRef< CSeq_loc > Seq_loc_Merge(const CSeq_loc &loc, CSeq_loc::TOpFlags flags, CScope *scope)
Merge ranges in the seq-loc.
CRef< CSeq_loc > Seq_loc_Add(const CSeq_loc &loc1, const CSeq_loc &loc2, CSeq_loc::TOpFlags flags, CScope *scope)
Add two seq-locs.
@ fCompareOverlapping
Check if seq-locs are overlapping.
@ eSame
CSeq_locs contain each other.
CConstRef< CSeq_feat > GetOverlappingGene(const CSeq_loc &loc, CScope &scope, ETransSplicing eTransSplicing=eTransSplicing_Auto)
static void Translate(const string &seq, string &prot, const CGenetic_code *code, bool include_stop=true, bool remove_trailing_X=false, bool *alt_start=NULL, bool is_5prime_complete=true, bool is_3prime_complete=true)
Translate a string using a specified genetic code.
@ eGetId_Best
return the "best" gi (uses FindBestScore(), with CSeq_id::CalculateScore() as the score function
CBioseq_Handle GetBioseqHandle(const CSeq_id &id)
Get bioseq handle by seq-id.
CSeq_feat_Handle GetSeq_featHandle(const CSeq_feat &feat, EMissing action=eMissing_Default)
CConstRef< CBioseq > GetCompleteBioseq(void) const
Get the complete bioseq.
const CSeq_annot_Handle & GetAnnot(void) const
Get handle to seq-annot for this feature.
TSeqPos GetBioseqLength(void) const
CSeq_entry_Handle GetParentEntry(void) const
Get parent Seq-entry handle.
CSeq_entry_EditHandle GetEditHandle(void) const
Get 'edit' version of handle.
TInst_Length GetInst_Length(void) const
CScope & GetScope(void) const
Get scope this handle belongs to.
CConstRef< CSeq_feat > GetOriginalSeq_feat(void) const
void Replace(const CSeq_feat &new_feat) const
Replace the feature with new Seq-feat object.
const TInst & GetInst(void) const
CRef< C > Ref(C *object)
Helper functions to get CRef<> and CConstRef<> objects.
TObjectType * GetPointer(void) THROWS_NONE
Get pointer,.
void Reset(void)
Reset reference object.
#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 bool EndsWith(const CTempString str, const CTempString end, ECase use_case=eCase)
Check if a string ends with a specified suffix value.
static string IntToString(int value, TNumToStringFlags flags=0, int base=10)
Convert int to string.
static bool StartsWith(const CTempString str, const CTempString start, ECase use_case=eCase)
Check if a string starts with a specified prefix value.
@ eNocase
Case insensitive compare.
TTo GetTo(void) const
Get the To member data.
TFrom GetFrom(void) const
Get the From member data.
bool IsSetAnticodon(void) const
location of anticodon Check if a value has been assigned to Anticodon data member.
void SetAnticodon(TAnticodon &value)
Assign a value to Anticodon data member.
void ResetAnticodon(void)
Reset Anticodon data member.
bool IsSetData(void) const
the specific data Check if a value has been assigned to Data data member.
void SetLocation(TLocation &value)
Assign a value to Location data member.
bool IsCdregion(void) const
Check if variant Cdregion is selected.
void ResetCode_break(void)
Reset Code_break data member.
const TLocation & GetLocation(void) const
Get the Location member data.
list< CRef< CCode_break > > TCode_break
TFrame GetFrame(void) const
Get the Frame member data.
const TData & GetData(void) const
Get the Data member data.
void SetData(TData &value)
Assign a value to Data data member.
TCode_break & SetCode_break(void)
Assign a value to Code_break data member.
const TCdregion & GetCdregion(void) const
Get the variant data.
const TCode_break & GetCode_break(void) const
Get the Code_break member data.
bool IsSetProduct(void) const
product of process Check if a value has been assigned to Product data member.
bool IsSetCode_break(void) const
individual exceptions Check if a value has been assigned to Code_break data member.
bool IsSetFrame(void) const
Check if a value has been assigned to Frame data member.
bool IsSetLocation(void) const
feature made from Check if a value has been assigned to Location data member.
@ eFrame_not_set
not set, code uses one
@ eFrame_three
reading frame
bool IsSet(void) const
Check if a value has been assigned to data member.
void SetTo(TTo value)
Assign a value to To data member.
const TFuzz_from & GetFuzz_from(void) const
Get the Fuzz_from member data.
void SetPoint(TPoint value)
Assign a value to Point data member.
void SetId(TId &value)
Assign a value to Id data member.
void SetA(TA &value)
Assign a value to A data member.
bool IsSetId(void) const
WARNING: this used to be optional Check if a value has been assigned to Id data member.
void ResetFuzz_to(void)
Reset Fuzz_to data member.
bool IsMix(void) const
Check if variant Mix is selected.
bool CanGetFuzz_to(void) const
Check if it is safe to call GetFuzz_to method.
const TB & GetB(void) const
Get the B member data.
list< CRef< CSeq_interval > > Tdata
ENa_strand
strand of nucleic acid
const Tdata & Get(void) const
Get the member data.
bool CanGetStrand(void) const
Check if it is safe to call GetStrand method.
void ResetPoints(void)
Reset Points data member.
TStrand GetStrand(void) const
Get the Strand member data.
const TId & GetId(void) const
Get the Id member data.
bool IsSetPoint(void) const
Check if a value has been assigned to Point data member.
bool IsSetPoints(void) const
Check if a value has been assigned to Points data member.
bool IsPacked_pnt(void) const
Check if variant Packed_pnt is selected.
Tdata & Set(void)
Assign a value to data member.
const TPnt & GetPnt(void) const
Get the variant data.
TPoint GetPoint(void) const
Get the Point member data.
const TFuzz_to & GetFuzz_to(void) const
Get the Fuzz_to member data.
bool IsSetA(void) const
connection to a least one residue Check if a value has been assigned to A data member.
void SetStrand(TStrand value)
Assign a value to Strand data member.
bool IsSetStrand(void) const
Check if a value has been assigned to Strand data member.
TFrom GetFrom(void) const
Get the From member data.
bool CanGetTo(void) const
Check if it is safe to call GetTo method.
void SetFuzz(TFuzz &value)
Assign a value to Fuzz data member.
bool IsSetFuzz(void) const
Check if a value has been assigned to Fuzz data member.
list< CRef< CSeq_loc > > Tdata
bool IsEquiv(void) const
Check if variant Equiv is selected.
E_Choice Which(void) const
Which variant is currently selected.
const TId & GetId(void) const
Get the Id member data.
const TId & GetId(void) const
Get the Id member data.
bool IsSet(void) const
Check if a value has been assigned to data member.
void SetFrom(TFrom value)
Assign a value to From data member.
bool IsBond(void) const
Check if variant Bond is selected.
bool IsSetFuzz(void) const
Check if a value has been assigned to Fuzz data member.
const Tdata & Get(void) const
Get the member data.
const TPacked_pnt & GetPacked_pnt(void) const
Get the variant data.
void SetFuzz(TFuzz &value)
Assign a value to Fuzz data member.
const Tdata & Get(void) const
Get the member data.
void ResetFuzz_from(void)
Reset Fuzz_from data member.
const TEquiv & GetEquiv(void) const
Get the variant data.
TPoints & SetPoints(void)
Assign a value to Points data member.
list< CRef< CSeq_loc > > Tdata
vector< TSeqPos > TPoints
virtual void Reset(void)
Reset the whole object.
void SetFuzz_to(TFuzz_to &value)
Assign a value to Fuzz_to data member.
void SetFuzz_from(TFuzz_from &value)
Assign a value to Fuzz_from data member.
bool IsPacked_int(void) const
Check if variant Packed_int is selected.
const TA & GetA(void) const
Get the A member data.
bool IsSetTo(void) const
Check if a value has been assigned to To data member.
bool IsSet(void) const
Check if a value has been assigned to data member.
bool CanGetB(void) const
Check if it is safe to call GetB method.
bool IsSetStrand(void) const
Check if a value has been assigned to Strand data member.
Tdata & Set(void)
Assign a value to data member.
bool IsSetFuzz_to(void) const
Check if a value has been assigned to Fuzz_to data member.
void Reset(void)
Reset data member.
Tdata & Set(void)
Assign a value to data member.
void ResetFrom(void)
Reset From data member.
const TPoints & GetPoints(void) const
Get the Points member data.
TStrand GetStrand(void) const
Get the Strand member data.
bool IsSetId(void) const
WARNING: this used to be optional Check if a value has been assigned to Id data member.
TTo GetTo(void) const
Get the To member data.
bool IsSetFrom(void) const
Check if a value has been assigned to From data member.
bool IsInt(void) const
Check if variant Int is selected.
const TInt & GetInt(void) const
Get the variant data.
bool IsNull(void) const
Check if variant Null is selected.
void SetB(TB &value)
Assign a value to B data member.
bool IsSetId(void) const
Check if a value has been assigned to Id data member.
bool IsSetFuzz_from(void) const
Check if a value has been assigned to Fuzz_from data member.
const TFuzz & GetFuzz(void) const
Get the Fuzz member data.
const TMix & GetMix(void) const
Get the variant data.
void ResetTo(void)
Reset To data member.
bool IsPnt(void) const
Check if variant Pnt is selected.
bool IsSetB(void) const
other end may not be available Check if a value has been assigned to B data member.
const TPacked_int & GetPacked_int(void) const
Get the variant data.
const TBond & GetBond(void) const
Get the variant data.
bool CanGetFrom(void) const
Check if it is safe to call GetFrom method.
bool CanGetFuzz_from(void) const
Check if it is safe to call GetFuzz_from method.
@ eNa_strand_both_rev
in reverse orientation
@ e_not_set
No variant selected.
@ e_Equiv
equivalent sets of locations
@ e_Empty
to NULL one Seq-id in a collection
@ e_Feat
indirect, through a Seq-feat
TRepr GetRepr(void) const
Get the Repr member data.
const TInst & GetInst(void) const
Get the Inst member data.
bool IsSetRepr(void) const
Check if a value has been assigned to Repr data member.
bool IsSetExt(void) const
extensions for special types Check if a value has been assigned to Ext data member.
bool IsSetInst(void) const
the sequence data Check if a value has been assigned to Inst data member.
TLength GetLength(void) const
Get the Length member data.
bool IsDelta(void) const
Check if variant Delta is selected.
const TExt & GetExt(void) const
Get the Ext member data.
const TDelta & GetDelta(void) const
Get the variant data.
const Tdata & Get(void) const
Get the member data.
list< CRef< CDelta_seq > > Tdata
@ eRepr_delta
sequence made by changes (delta) to others
unsigned int
A callback function used to compare two keys in a database.
CRef< CSeq_loc > SeqLocExtend5(const CSeq_loc &loc, TSeqPos pos, CScope *scope)
bool IsExtendableRight(TSeqPos right, const CBioseq &seq, CScope *scope, TSeqPos &extend_len)
bool IsExtendableLeft(TSeqPos left, const CBioseq &seq, CScope *scope, TSeqPos &extend_len)
void AdjustFrameFor5Extension(CSeq_feat &feat, size_t diff)
bool OkToAdjustLoc(const CSeq_interval &interval, const CSeq_id *seqid)
void SeqLocAdjustForInsert(CSeq_interval &interval, TSeqPos insert_from, TSeqPos insert_to, const CSeq_id *seqid)
void CdregionAdjustForTrim(CCdregion &cdr, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
void ReverseComplementCDRegion(CCdregion &cdr, CScope &scope)
bool AdjustFeatureEnd3(CSeq_feat &cds, vector< CRef< CSeq_feat > > related_features, CScope &scope)
void FeatureAdjustForInsert(CSeq_feat &feat, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
bool ExtendPartialFeatureEnds(CBioseq_Handle bsh)
bool s_StrandsConsistent(const CSeq_interval &a, const CSeq_interval &b)
void ReverseComplementFeature(CSeq_feat &feat, CScope &scope)
bool s_PPntCompareMinus(const TSeqPos &p1, const TSeqPos &p2)
string PrintSeqIntUseBestID(const CSeq_interval &seq_int, CScope &scope, bool range_only)
void TrnaAdjustForTrim(CTrna_ext &trna, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
void SeqLocAdjustForTrim(CSeq_interval &interval, TSeqPos cut_from, TSeqPos cut_to, const CSeq_id *seqid, bool &bCompleteCut, TSeqPos &trim5, bool &bAdjusted)
void NormalizeLoc(CSeq_loc &loc)
bool CorrectIntervalOrder(CPacked_seqpnt &ppnt)
bool AdjustFeatureEnd5(CSeq_feat &cds, vector< CRef< CSeq_feat > > related_features, CScope &scope)
string PrintBestSeqId(const CSeq_id &sid, CScope &scope)
void TrnaAdjustForInsert(CTrna_ext &trna, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
bool OneIdOneStrand(const CSeq_loc &loc, const CSeq_id **id, ENa_strand &strand)
void ReverseComplementLocation(CSeq_interval &interval, CScope &scope)
bool ApplyPolicyToFeature(const CLocationEditPolicy &policy, const CSeq_feat &orig_feat, CScope &scope, bool adjust_gene, bool retranslate_cds)
bool IsExtendable(const CSeq_feat &cds, CScope &scope)
string SeqLocPrintUseBestID(const CSeq_loc &seq_loc, CScope &scope, bool range_only)
CRef< CSeq_loc > SeqLocExtend3(const CSeq_loc &loc, TSeqPos pos, CScope *scope)
string PrintPntAndPntsUseBestID(const CSeq_loc &seq_loc, CScope &scope, bool range_only)
bool s_PPntComparePlus(const TSeqPos &p1, const TSeqPos &p2)
void FeatureAdjustForTrim(CSeq_feat &feat, TSeqPos from, TSeqPos to, const CSeq_id *seqid, bool &bCompleteCut, bool &bTrimmed)
void CdregionAdjustForInsert(CCdregion &cdr, TSeqPos from, TSeqPos to, const CSeq_id *seqid)
static const string strand_symbol[]
void ReverseComplementTrna(CTrna_ext &trna, CScope &scope)
CRef< CSeq_interval > SplitLocationForGap(CSeq_interval &before, TSeqPos start, TSeqPos stop, const CSeq_id *seqid, bool &cut, unsigned int options)
CRef< CSeq_loc > SeqLocExtend(const CSeq_loc &loc, size_t pos, CScope *scope)
@ eSplitLocOption_split_in_intron
@ eSplitLocOption_make_partial
@ eSplitLocOption_split_in_exon
Portable reference counted smart and weak pointers using CWeakRef, CRef, CObject and CObjectEx.
Generic utility macros and templates for exploring NCBI objects.
bool seq_mac_is_sorted(Iter first, Iter last, Comp comp)
static SLJIT_INLINE sljit_ins l(sljit_gpr r, sljit_s32 d, sljit_gpr x, sljit_gpr b)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4