A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/seq__text__ds_8cpp_source.html below:

NCBI C++ ToolKit: src/gui/widgets/seq_text/seq_text_ds.cpp Source File

134  bool

in_source =

false

;

142  if

(sequence_pos >= it->GetSequenceStart() && sequence_pos <= it->GetSequenceStop()) {

143

source_pos = it->GetSourceStart() + sequence_pos - it->GetSequenceStart();

147

}

else if

(sequence_pos < it->GetSequenceStart()) {

148

source_pos = it->GetSourceStart();

157  if

(found_in_source !=

NULL

) {

158

*found_in_source = in_source;

169  if

(source_pos >= it->GetSourceStart() && source_pos <= it->GetSourceStop()) {

170

sequence_pos = it->GetSequenceStart() + source_pos - it->GetSourceStart();

187  if

(it->GetSourceStart() > stop) {

190

it->GetSeqString(start, stop,

buffer

);

197  for

(

unsigned int i

= 0;

i

< seq.length();

i

++) {

212  if

(it->GetSourceStart() > stop) {

215

it->GetSeqData(start, stop,

buffer

, feat_sel

);

218  if

(showFeatAsLower) {

236

}

else if

(subtype1 < subtype2) {

256

splice_sites.clear();

269  int l

= (stop_offset - start_offset) + 1;

270

splice_sites.reserve(

l

);

271

splice_sites.resize(

l

,

false

);

272

subtypes.reserve(

l

);

281  if

(it->GetSourceStart() > stop_offset) {

284

it->GetFeatureData(start_offset, stop_offset, cfg, pParent, subtypes, splice_sites, variations);

293  bool

is_mRNA =

true

;

295  for

(

CSeq_loc_CI

seq_loc_it (*

m_Loc

); seq_loc_it && is_mRNA; ++ seq_loc_it) {

328  if

(!pParent)

return

;

329

subtypes.reserve((stop_offset - start_offset) + 1);

334  if

(it->GetSourceStart() > stop_offset) {

337

it->GetSubtypesForAlternatingExons(start_offset, stop_offset, pParent, subtypes, even);

349  if

(it->GetSourceStart() > stop_offset) {

352

it->GetVariations(start_offset, stop_offset, variations);

360  if

(pParent ==

NULL

)

return

;

367

it->RenderFeatureExtras (pParent, start_offset, stop_offset);

380  bool

is_first =

true

;

390  else if

(

offset

>= start_offset)

392

breaks.push_back (

offset

);

397  offset

+= seq_stop - seq_start + 1;

409  string

s =

"Sequence : "

;

410

unique_ptr<sequence::CDeflineGenerator>

gen

(

new

sequence::CDeflineGenerator());

424

vector<CConstRef<CSeq_feat> > features;

427  if

(!seq_id)

return

features;

435

it->GetFeaturesAtPosition(source_pos, features);

444  return new CFeat_CI

(handle, range, *feat_sel);

448  return new CFeat_CI

(handle, range, sel);

454  string

tooltip_text =

""

;

457

it->GetToolTipForPosition(source_pos, tooltip_text);

473  string

search_buffer;

475  if

(fragment.length() > data_len - start_search) {

479

search_buffer_len =

max

((

int

) 1000, (

int

)(3 * fragment.length()));

480

search_buffer_len =

min

(search_buffer_len, data_len - start_search);

482  while

(start_search < data_len - fragment.length() + 1) {

483

end_search = start_search + search_buffer_len;

486  if

(pos != string::npos) {

487  return static_cast<int>

(pos + start_search);

489

start_search =

static_cast<TSeqPos>

(end_search - fragment.length() + 1);

504  TSeqPos

start_search = 0, end_search;

505  string

search_buffer;

509  if

(fragment.length() > data_len - start_search) {

513

search_buffer_len =

max

((

int

) 1000, (

int

)(3 * fragment.length()));

514

search_buffer_len =

min

(search_buffer_len, data_len - start_search);

516  while

(!cancel->

IsCanceled

() && start_search < data_len - fragment.length() + 1) {

517

end_search = start_search + search_buffer_len;

520  while

(pos != string::npos) {

521

locations.push_back(

static_cast<TSeqPos>

(pos + start_search));

522  if

(end_search > pos + fragment.length()) {

528

start_search =

static_cast<TSeqPos>

(end_search - fragment.length() + 1);

543  offset

+= seq_loc_it.GetRange().GetLength();

549

: m_Feat(scope, loc), m_Offset(

offset

)

553  m_Seq

= scope.GetBioseqHandle(*(loc.GetId()));

615  buffer

.append (seq_piece);

623  if

(IntersectingSourceInterval(src_start, src_stop)) {

626

m_Vect.GetSeqData (src_start + GetSequenceStart(), src_stop + GetSequenceStart() + 1, seq_piece);

629  CFeat_CI

feat_it(m_Seq.GetScope(), *m_Loc, feat_sel ? *feat_sel : sel);

641  if

(feat_stop < GetSequenceStart() || feat_start > GetSequenceStop()) {

646

feat_start =

max

(0,

int

(feat_start - GetSequenceStart()));

647

feat_stop =

max

(0,

int

(feat_stop - GetSequenceStart()));

649  if

(feat_stop < src_start || feat_start > src_stop) {

654

feat_start = (feat_start < src_start) ? 0 : feat_start - src_start;

655

feat_stop = (feat_stop - src_start > seq_piece.size() - 1) ?

static_cast<TSeqPos>

(seq_piece.size() - 1) : feat_stop - src_start;

657  while

(feat_start <= feat_stop)

659

seq_piece [feat_start] =

tolower

(seq_piece [feat_start]);

667  buffer

.append (seq_piece);

679  string

feat_title =

""

;

682  if

(!feat_title.empty()) {

683  if

(!tooltip_text.empty()) {

684

tooltip_text.append (

"\n"

);

686

tooltip_text.append (feat_title);

696  if

(pParent ==

NULL

)

return

;

730  int

subtype =

f

->GetFeatSubtype();

771  bool

replace_found =

false

;

778  m_Vect

.GetSeqData (feat_left, feat_right + 1, seq_piece);

792

replace_found =

true

;

796  if

(!replace_found) {

810  if

(!pParent)

return

;

843  TSeqPos

start_offset = source_pos;

844  TSeqPos

stop_offset = start_offset;

851  for

(

CSeq_loc_CI

loc_it(

f

->GetLocation()); loc_it; ++loc_it) {

853  if

(this_range.

GetFrom

() <= start_offset && this_range.

GetTo

() >= start_offset) {

854

features.push_back(

f

->GetSeq_feat());

870  string

splice_buffer;

871  bool

is_start =

true

;

875

need_unset[0] =

false

;

876

need_unset[1] =

false

;

885  if

(feat_stop <= start_offset || feat_start >= stop_offset)

887

feat_start -= start_offset;

888

feat_stop -= start_offset;

890  bool

is_minus =

false

;

896  CBioseq_Handle

handle =

m_Seq

.GetScope().GetBioseqHandle(*loc_it.GetEmbeddingSeq_loc().GetId());

898  if

(feat_start > 2 && ! is_start && feat_start < stop_offset && feat_start - 2 >= start_offset) {

901

vect.

GetSeqData

(feat_start - 2, feat_start, splice_buffer);

903  TSeqPos

interval_pos = feat_start - 2;

905

splice_sites[interval_pos +

m_Offset

] =

true

;

907

interval_pos = feat_start - 1;

909

splice_sites[interval_pos +

m_Offset

] =

true

;

913

need_unset [0] =

false

;

914

need_unset [1] =

false

;

915  if

(feat_stop < splice_sites.size() - 2 && feat_stop <= handle.

GetBioseqLength

() - 2

916

&& feat_stop > start_offset && feat_stop + 3 < stop_offset) {

919

vect.

GetSeqData

(feat_stop + 1, feat_stop + 3, splice_buffer);

921  TSeqPos

interval_pos = feat_stop + 1;

923

splice_sites[interval_pos] =

true

;

924

need_unset [0] =

true

;

925

unset_pos [0] = interval_pos;

927

interval_pos = feat_stop + 2;

929

splice_sites[interval_pos] =

true

;

930

need_unset [1] =

true

;

931

unset_pos [1] = interval_pos;

939  if

(need_unset [0]) {

940

splice_sites[unset_pos[0]] =

false

;

943

splice_sites[unset_pos[1]] =

false

;

953  id

->Assign(*(

m_Seq

.GetId().front().GetSeqId()));

954  cmp

->SetInt().SetId(*

id

);

963  bool

is_splice =

false

;

965  if

(splice_buffer.length() < 2) {

967

}

else if

(before_loc) {

969  if

((splice_buffer[0] ==

'A'

&& (splice_buffer[1] ==

'C'

|| splice_buffer[1] ==

'G'

))

970

|| (splice_buffer[0] ==

'G'

&& splice_buffer[1] ==

'C'

)) {

976  if

(splice_buffer[0] ==

'A'

&& (splice_buffer[1] ==

'G'

|| splice_buffer[1] ==

'C'

)) {

984  if

((splice_buffer[0] ==

'C'

|| splice_buffer[0] ==

'G'

) && splice_buffer[1] ==

'T'

) {

990  if

((splice_buffer[0] ==

'G'

&& (splice_buffer[1] ==

'T'

|| splice_buffer[1] ==

'C'

))

991

|| (splice_buffer[0] ==

'C'

&& splice_buffer[1] ==

'T'

)) {

@ eExtreme_Positional

numerical value

@ eSubtype_bad

These no longer need to match the FEATDEF values in the C toolkit's objfdef.h.

bool GetShow(int subtype) const

CSeqTextPaneConfig::EFeatureDisplayType GetFeatureColorationChoice()

bool SourcePosToIntervalPos(TSeqPos &pos) const

void GetFeaturesAtPosition(TSeqPos source_pos, vector< CConstRef< objects::CSeq_feat > > &features)

bool IntersectingSourceInterval(TSeqPos &src_start, TSeqPos &src_stop) const

void GetSeqData(TSeqPos src_start, TSeqPos src_stop, string &buffer, objects::SAnnotSelector *feat_sel) const

void RenderFeatureExtras(ISeqTextGeometry *pParent, TSeqPos start_offset, TSeqPos stop_offset)

objects::CBioseq_Handle m_Seq

~CSeqTextDataSourceInterval()

objects::CSeqVector m_Vect

bool SequencePosToIntervalPos(TSeqPos &pos) const

TSeqPos GetSequenceStart() const

void GetSubtypesForAlternatingExons(TSeqPos start_offset, TSeqPos stop_offset, ISeqTextGeometry *pParent, CSeqTextDefs::TSubtypeVector &subtypes, bool &even)

void x_AddVariationsFromFeature(const objects::CSeq_feat &feat, const objects::CSeq_loc &loc, CSeqTextDefs::TVariationGraphVector &variations) const

void GetSeqString(TSeqPos src_start, TSeqPos src_stop, string &buffer) const

void LookForSpliceJunctions(const objects::CMappedFeat &feat, CSeqTextDefs::TSpliceSiteVector &splice_sites, TSeqPos start_offset, TSeqPos stop_offset) const

CSeqTextDataSourceInterval(const objects::CSeq_loc &loc, objects::CScope &scope, TSeqPos offset)

bool x_IsSpliceSite(string splice_buffer, bool before_loc, bool is_minus) const

void GetFeatureData(TSeqPos start_offset, TSeqPos stop_offset, CSeqTextConfig *cfg, ISeqTextGeometry *pParent, CSeqTextDefs::TSubtypeVector &subtypes, CSeqTextDefs::TSpliceSiteVector &splice_sites, CSeqTextDefs::TVariationGraphVector &variations)

CRef< objects::CSeq_loc > m_Loc

void GetToolTipForPosition(TSeqPos src_pos, string &tooltip_text)

CRef< objects::CSeq_loc > x_GetSeqLocForInterval(TSeqPos interval_start, TSeqPos interval_stop) const

TSeqPos GetSequenceStop() const

void GetVariations(TSeqPos start_offset, TSeqPos stop_offset, CSeqTextDefs::TVariationGraphVector &variations)

vector< CSeqTextDataSourceInterval > TIntervalList

CRef< objects::CSeq_entry > m_Sep

virtual ~CSeqTextDataSource()

void RenderFeatureExtras(ISeqTextGeometry *pParent, CGlPane &pane, TSeqPos seq_start, TSeqPos seq_stop)

CRef< objects::CSeq_loc > m_Loc

void GetSeqData(TSeqPos start, TSeqPos stop, string &buffer, objects::SAnnotSelector *feat_sel=NULL, bool showFeatAsLower=false)

void FindSequenceFragmentList(const string &fragment, CSeqTextDefs::TSeqPosVector &locations, ICanceled *cancel)

const objects::CSeq_loc * GetLoc() const

objects::CBioseq_Handle m_SubjectHandle

void GetFeatureData(TSeqPos start_offset, TSeqPos stop_offset, CSeqTextConfig *cfg, ISeqTextGeometry *pParent, CSeqTextDefs::TSubtypeVector &subtypes, CSeqTextDefs::TSpliceSiteVector &splice_sites, CSeqTextDefs::TVariationGraphVector &variations)

static int ChooseBetterSubtype(int subtype1, int subtype2)

void GetIntervalBreaks(TSeqPos start_offset, TSeqPos stop_offset, CSeqTextDefs::TSeqPosVector &breaks)

string GetToolTipForSourcePos(TSeqPos source_pos)

CSeqTextDataSource(objects::CSeq_entry &sep, objects::CScope &scope)

int FindSequenceFragment(const string &fragment, TSeqPos start_search)

vector< CConstRef< objects::CSeq_feat > > GetFeaturesAtPosition(TSeqPos source_pos)

TSeqPos SequencePosToSourcePos(TSeqPos sequence_pos, bool *found_in_source=NULL)

objects::CScope & GetScope()

void GetSubtypesForAlternatingExons(TSeqPos start_offset, TSeqPos stop_offset, ISeqTextGeometry *pParent, CSeqTextDefs::TSubtypeVector &subtypes)

TIntervalList m_Intervals

void GetVariations(TSeqPos start_offset, TSeqPos stop_offset, CSeqTextDefs::TVariationGraphVector &variations)

TSeqPos SourcePosToSequencePos(TSeqPos source_pos)

CRef< objects::CScope > m_Scope

void x_PopulateFeatureIterators()

void GetSeqString(TSeqPos start, TSeqPos stop, string &buffer)

vector< CSeqTextVariationGraph > TVariationGraphVector

vector< bool > TSpliceSiteVector

vector< int > TSubtypeVector

vector< TSeqPos > TSeqPosVector

class CSeqTextVariationGraph

namespace ncbi::objects::

Seq-loc iterator class – iterates all intervals from a seq-loc in the correct order.

Interface for testing cancellation request in a long lasting operation.

virtual void STG_RenderFeatureExtras(const objects::CMappedFeat &feat)=0

virtual void STG_SetSubtypesForFeature(CSeqTextDefs::TSubtypeVector &subtypes, const objects::CSeq_loc &loc, int subtype, TSeqPos start_offset, TSeqPos stop_offset)=0

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.

#define NCBI_THROW(exception_class, err_code, message)

Generic macro to throw an exception, given the exception class, error code and message string.

static objects::SAnnotSelector GetAnnotSelector(TAnnotFlags flags=0)

request an annotation selector for a given type

static void GetLabel(const CObject &obj, string *label, ELabelType type=eDefault)

CConstRef< CSeq_id > GetSeqId(void) const

TSeqPos GetStart(ESeqLocExtremes ext) const

Return start and stop positions of the seq-loc.

const CSeq_id * GetId(void) const

Get the id of the location return NULL if has multiple ids or no id at all.

TSeqPos GetStop(ESeqLocExtremes ext) const

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.

@ eGetId_Best

return the "best" gi (uses FindBestScore(), with CSeq_id::CalculateScore() as the score function

CSeq_entry_Handle GetSeq_entryHandle(CDataLoader *loader, const TBlobId &blob_id, EMissing action=eMissing_Default)

Get Seq-entry handle by its blob-id, with possible loading.

CBioseq_Handle GetBioseqHandle(const CSeq_id &id)

Get bioseq handle by seq-id.

TSeqPos GetBioseqLength(void) const

TInst_Mol GetInst_Mol(void) const

CConstRef< CSeq_id > GetSeqId(void) const

Get id which can be used to access this bioseq handle Throws an exception if none is available.

CSeqVector GetSeqVector(EVectorCoding coding, ENa_strand strand=eNa_strand_plus) const

Get sequence: Iupacna or Iupacaa if use_iupac_coding is true.

bool CanGetInst_Mol(void) const

@ eCoding_Iupac

Set coding to printable coding (Iupacna or Iupacaa)

const CSeq_loc & GetLocation(void) const

void GetSeqData(TSeqPos start, TSeqPos stop, string &buffer) const

Fill the buffer string with the sequence data for the interval [start, stop).

TObjectType * GetNCPointer(void) const THROWS_NONE

Get pointer,.

void Reset(void)

Reset reference object.

TObjectType & GetObject(void)

Get object.

CRange< TSeqPos > TSeqRange

typedefs for sequence ranges

#define END_NCBI_SCOPE

End previously defined NCBI scope.

#define BEGIN_NCBI_SCOPE

Define ncbi namespace.

virtual bool IsCanceled(void) const =0

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 SIZE_TYPE FindNoCase(const CTempString str, const CTempString pattern, SIZE_TYPE start, SIZE_TYPE end, EOccurrence which=eFirst)

Find the pattern in the specified range of a string using a case insensitive search.

TTo GetTo(void) const

Get the To member data.

TFrom GetFrom(void) const

Get the From member data.

bool CanGetQual(void) const

Check if it is safe to call GetQual method.

const TQual & GetQual(void) const

Get the Qual member data.

vector< CRef< CGb_qual > > TQual

TBiomol GetBiomol(void) const

Get the Biomol member data.

const TMolinfo & GetMolinfo(void) const

Get the variant data.

@ e_Molinfo

info on the molecule and techniques

static bool GetSeqId(const T &d, set< string > &labels, const string name="", bool detect=false, bool found=false)

USING_SCOPE(ncbi::objects)

void InvertCase(string &seq)

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