NCBI C++ ToolKit
dbvar_track.cpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: dbvar_track.cpp 47443 2023-04-05 19:40:22Z evgeniev $
2  * ===========================================================================
3  *
4  * PUBLIC DOMAIN NOTICE
5  * National Center for Biotechnology Information
6  *
7  * This software/database is a "United States Government Work" under the
8  * terms of the United States Copyright Act. It was written as part of
9  * the author's official duties as a United States Government employee and
10  * thus cannot be copyrighted. This software/database is freely available
11  * to the public for use. The National Library of Medicine and the U.S.
12  * Government have not placed any restriction on its use or reproduction.
13  *
14  * Although all reasonable efforts have been taken to ensure the accuracy
15  * and reliability of the software and data, the NLM and the U.S.
16  * Government do not and cannot warrant the performance or results that
17  * may be obtained by using this software or data. The NLM and the U.S.
18  * Government disclaim all warranties, express or implied, including
19  * warranties of performance, merchantability or fitness for any particular
20  * purpose.
21  *
22  * Please cite the author in any work or product based on this material.
23  *
24  * ===========================================================================
25  *
26  * Authors: Liangshou Wu
27  *
28  * File Description:
29  *
30  */
31 
32 #include <ncbi_pch.hpp>
33 
35 
41 #include <gui/objutils/utils.hpp>
43 #include <gui/objects/TextBox.hpp>
44 #include <objmgr/util/sequence.hpp>
45 #include <util/checksum.hpp>
46 
49 
50 ///////////////////////////////////////////////////////////////////////////////
51 /// CVarTrack
52 ///////////////////////////////////////////////////////////////////////////////
53 
55  "Variation features");
56 
58  : CFeatureTrack(ds, r_cntx)
59 {
60 }
61 
62 
64 {}
65 
66 
68 {
69  return m_TypeInfo;
70 }
71 
72 
74 {
75  if (m_ZoomToSee) {
76  string msg = "Zoom to see if data exists for this region";
78  TModelUnit x = (range.GetFrom() + range.GetTo() ) * 0.5;
80  CRef<CCommentGlyph> comment(new CCommentGlyph(msg, TModelPoint(x, 0.0)));
81  objs.push_back(comment);
82  CRef<CCommentConfig> config(new CCommentConfig(*x_GetGlobalConfig()->GetCommentConfig()));
83  config->m_ShowConnection = false;
84  SetCommentGlyphs(objs, config);
85  return;
86  }
88 }
89 
90 void CVarTrack::x_LoadSettings(const string& preset_style, const TKeyValuePairs &settings)
91 {
92  CFeatureTrack::x_LoadSettings(preset_style, settings);
93  auto it = settings.find("zoom_to_see");
94  m_ZoomToSee = (it != settings.end() && NStr::StringToBool(it->second));
95 }
96 
98 {
100  // Sort the features to stabilize the regression tests
101  auto sort_by_pos = [] (CRef<CSeqGlyph> const& g1, CRef<CSeqGlyph> const& g2) -> bool
102  {
103  if (g1->GetLeft() != g2->GetLeft())
104  return g1->GetLeft() < g2->GetLeft();
105  else
106  return g1->GetTop() < g2->GetTop();
107  };
108  CLayoutGroup& group = dynamic_cast<CLayoutGroup&>(*this);
109  group.GetChildren().sort(sort_by_pos);
110 }
111 
112 string GenerateSignature(const string& title,
113  const string& annot_name,
114  TGi gi,
116 {
117  char buff[128];
118  Uint2 type;
119 
120  // create type
122 // type |= BinType;
123 
124  // create checksum
126  Uint4 checksum(0);
127  if (!title.empty()) {
128  cs.AddLine(title);
129  checksum = cs.GetChecksum();
130  }
131 
132  CChecksum cs_name(CChecksum::eCRC32);
133  Uint4 checksum_name;
134  cs_name.AddLine(annot_name);
135  checksum_name = cs_name.GetChecksum();
136 
137  sprintf(buff, "gi|%d-%08x-%08x-%04x-%08x-%08x",
138  GI_TO(int, gi), range.GetFrom(), range.GetTo(),
139  type, checksum, checksum_name);
140 
141  return string(buff);
142 }
143 
145 {
146  if (!GetChildren().empty()) {
147  TModelUnit tb_height = x_GetTBHeight();
148 
149  // for Associated results/GAP types of tracks, generate a separate area for the track caption
150  CHTMLActiveArea area;
152 
153  // adjust the bounds height to that of the caption only
154  TVPRect& bound(area.m_Bounds);
155  bound.SetBottom(bound.Top() + (TVPUnit)tb_height + (tb_height > 0.0 ? 2 : 0));
156 
157  // user uploaded tracks are not based on NA annots
158  // we don't need to generate signature for them
159  // otherwise CTrackContainer will create multiple signatures
160  // and sviewer will issue seqgraphic call to get track's tooltip
161  // we don't want that for user uploaded tracks
162 
163  if (CSeqUtils::IsNAA(m_Annot)) {
164 
165  // find out the gi
167  sequence::eGetId_ForceGi).GetSeqId()),
168  m_DS->GetBioseqHandle().GetScope()));
169 
170  // create the signature
171  string sSignature(GenerateSignature(GetTitle(),
172  m_Annot,
173  gi,
174  area.m_SeqRange));
175  area.m_Signature = sSignature;
176  }
178  if (!(m_Attrs & fNavigable))
180  p_areas->push_back(area);
181  return &(p_areas->back());
182  }
183  auto area = CLayoutTrack::InitHTMLActiveArea(p_areas);
184  if (area && isRmtBased()) // turn off navigation for VCFTabix
185  area->m_Flags |= CHTMLActiveArea::fNoNavigation;
186  return area;
187 }
188 
189 ///////////////////////////////////////////////////////////////////////////////
190 /// CVarTrackFactory
191 ///////////////////////////////////////////////////////////////////////////////
194  ISGDataSourceContext* ds_context,
195  CRenderingContext* r_cntx,
196  const SExtraParams& params,
197  const TAnnotMetaDataList& src_annots) const
198 {
199  TAnnotNameTitleMap annots;
200  TTrackMap tracks;
201 
202  TKeyValuePairs track_settings;
203  CSGConfigUtils::ParseProfileString(params.m_TrackProfile, track_settings);
204 
206 
207  if (!params.m_Subkey.empty() && (0 != NStr::CompareNocase(params.m_Subkey, "vcf")))
208  subtype = CSeqFeatData::SubtypeNameToValue(params.m_Subkey);
209 
210  switch (subtype)
211  {
214  break;
215  default:
216  LOG_POST(Error << "CVarTrackFactory::CreateTracks() subtype " << params.m_Subkey << " is not supported!");
217  return tracks;
218  }
219 
220  if (params.m_SkipGenuineCheck && !params.m_Annots.empty()) {
221  ITERATE (SExtraParams::TAnnots, iter, params.m_Annots) {
222  annots.insert(TAnnotNameTitleMap::value_type(*iter, ""));
223  }
224  } else {
225 
226  TSeqRange range = params.m_Range;
227  if (range.Empty()) {
228  range = r_cntx->GetVisSeqRange();
229  }
230 
231  // collect non-NA tracks
232  CIRef<ISGDataSource> pre_ds = ds_context->GetDS(
233  typeid(CSGFeatureDSType).name(), object);
234  CSGFeatureDS* seq_ds = dynamic_cast<CSGFeatureDS*>(pre_ds.GetPointer());
235  seq_ds->SetDepth(params.m_Level);
236  seq_ds->SetAdaptive(params.m_Adaptive);
237 
239  sel.SetFeatSubtype(subtype);
240  seq_ds->GetAnnotNames_var(sel, range, annots);
241 
242  // collect NA tracks
243  if ( !src_annots.empty() ) {
244  GetMatchedAnnots(src_annots, params, annots);
245  }
246  }
247 
248  // create feature tracks
249  ITERATE (TAnnotNameTitleMap, iter, annots) {
250  if (iter->first == "SNP") // Skip data from dbSNP
251  continue;
252  CRef<CVarTrack> feat_track;
253  CIRef<ISGDataSource> ds = ds_context->GetDS(
254  typeid(CSGFeatureDSType).name(), object);
255  CSGFeatureDS* seq_ds = dynamic_cast<CSGFeatureDS*>(ds.GetPointer());
256  seq_ds->SetDepth(params.m_Level);
257  seq_ds->SetAdaptive(params.m_Adaptive);
258  if (track_settings.count("graph_cache_key") > 0) {
259  seq_ds->SetGraphCacheKey(track_settings["graph_cache_key"]);
260  }
261  if (track_settings.count("rmt_type") > 0) {
262  seq_ds->SetRemoteDataType(track_settings["rmt_type"]);
263  }
264 
265  // check the total levels of coverage graphs
266  //seq_ds->SetGraphLevels(iter->first);
267  seq_ds->SetFilter(params.m_Filter);
268  seq_ds->SetSortBy(params.m_SortBy);
269  feat_track.Reset(new CVarTrack(seq_ds, r_cntx));
270  feat_track->SetAnnot(iter->first);
271  feat_track->ExcludeAnnotName("SNP");
272  feat_track->SetFeatSubtype(subtype);
273  if ( !iter->second.empty() ) {
274  feat_track->SetTitle(iter->second);
275  }
276  tracks[iter->first] = feat_track.GetPointer();
277  }
278 
279  return tracks;
280 }
281 
283  const TAnnotMetaDataList& src_annots,
284  const ILayoutTrackFactory::SExtraParams& params,
285  TAnnotNameTitleMap& out_annots) const
286 {
287  if (params.m_Subkey != "variation")
288  ILayoutTrackFactory::GetMatchedAnnots(src_annots, params.m_Annots, "ftable", "variation", out_annots);
289 }
290 
292 {
293  return CVarTrack::m_TypeInfo.GetId();
294 }
295 
296 
298 {
300 }
301 
302 
304 CVarTrackFactory::GetSettings(const string& /*profile*/,
305  const TKeyValuePairs& settings,
306  const CTempTrackProxy* track_proxy) const
307 {
308  CRef<CTrackConfigSet> config_set(new CTrackConfigSet);
309  if (track_proxy) {
310  bool is_remote_track = (NStr::StartsWith(track_proxy->GetSource(), "http", NStr::eNocase) || NStr::StartsWith(track_proxy->GetSource(), "https", NStr::eNocase) || NStr::StartsWith(track_proxy->GetSource(), "ftp", NStr::eNocase));
311  config_set->Set().push_back(x_GetSettings(settings, track_proxy, is_remote_track));
312  } else {
313  config_set->Set().push_back(x_GetSettings(settings, nullptr, false));
314  config_set->Set().push_back(x_GetSettings(settings, nullptr, true));
315  }
316  return config_set;
317 }
318 
319 
321 CVarTrackFactory::x_GetSettings(const TKeyValuePairs& settings, const CTempTrackProxy* track_proxy, bool is_vcf_track) const
322 {
324  config->SetHelp() = GetThisTypeInfo().GetDescr();
325  config->SetLegend_text("anchor_5");
326  if (is_vcf_track) {
327  config->SetLegend_text("anchor_4");
328  config->SetSubkey("vcf");
329  }
330 
332  string hist_t = "0";
333 
334  ITERATE (TKeyValuePairs, iter, settings) {
335  try {
336  if (NStr::EqualNocase(iter->first, "Rendering")) {
337  rendering_str = iter->second;
338  if (rendering_str == "Histogram") // support legacy value
339  rendering_str = "Heatmap";
340  } else if (NStr::EqualNocase(iter->first, "HistThreshold")) {
341  int val = NStr::StringToInt(iter->second);
342  if (val > 0) hist_t = iter->second;
343  }
344  } catch (CException& e) {
345  LOG_POST(Warning << "CVarTrackFactory::x_LoadSettings() "
346  << e.GetMsg());
347  }
348  }
349 
350  string sort_by;
351  if (track_proxy) {
352  sort_by = track_proxy->GetSortBy();
353  }
354 
356  "Rendering", "Rendering options",
357  rendering_str,
358  "Rendering options for linked features.");
359 
360  choice->SetValues().push_back(
363  "Show all",
364  "All features, both parent and all child features",
365  "The bar on top represents the variant region. Each bar below represents \
366  the supporting level variants used to define this region.<br>Red: A Deletion or Loss<br> \
367  Green: A Gain or Insertion<br>Light Gray: An Inversion"));
368 
369  choice->SetValues().push_back(
372  "Show parent, Expand children upon a click",
373  "Show parent on one line and expand all children upon a mouse click.",
374  "The bar on top represents the variant region. The bars below appear upon a mouse click and each bar represents \
375  the supporting level variants used to define this region.<br>Red: A Deletion or Loss<br> \
376  Green: A Gain or Insertion<br>Light Gray: An Inversion"));
377 
378  choice->SetValues().push_back(
381  "Show parent, Merge children",
382  "Show parent on one line and all children merged below it.",
383  "The bar on top represents the variant region. The bar below represents \
384  all of the sample level variants merged onto a single line.<br>Red: A Deletion or Loss<br> \
385  Green: A Gain or Insertion<br>Light Gray: An Inversion"));
386 
387  choice->SetValues().push_back(
390  "Show children, not parent",
391  "Show only the supporting variants (chidlren) not the variant region (parent)",
392  "The bar represent supporting variants in this study.<br>Red: A Deletion or Loss<br>\
393  Green: A Gain or Insertion<br>Light Gray: An Inversion"));
394 
395  choice->SetValues().push_back(
398  "Show parent, not children ",
399  "Show the variant region (parent) not the supporting variants (children)",
400  "The bar represents the variant region."));
401 
402  choice->SetValues().push_back(
404  "SingleLine",
405  "Display on a single line",
406  "Track is displayed, with all features collapsed on a single line.",
407  "All the features are packed into one line."));
408  choice->SetValues().push_back(
410  "Heatmap",
411  "Heatmap",
412  "Track is displayed, with all features displayed as a heatmap.",
413  "All the features are packed and shown as a heatmap."));
414 
415  config->SetChoice_list().push_back(choice);
416 
418  "sort_by", "Sort variants by",
419  sort_by,
420  "Sort variants according to a selected criterion.");
421 
422  sortby_choice->SetValues().push_back(
424  "", "No sorting", "Don't sort variants", ""));
425 
427 
428  sortby_choice->SetValues().push_back(
430  descr.m_Name, descr.m_DisplayName, descr.m_Descr, ""));
431 
433  sortby_choice->SetValues().push_back(
435  descr.m_Name, descr.m_DisplayName, descr.m_Descr, ""));
436 
438  sortby_choice->SetValues().push_back(
440  descr.m_Name, descr.m_DisplayName, descr.m_Descr, ""));
441 
443  sortby_choice->SetValues().push_back(
445  descr.m_Name, descr.m_DisplayName, descr.m_Descr, ""));
446 
448  sortby_choice->SetValues().push_back(
450  descr.m_Name, descr.m_DisplayName, descr.m_Descr, ""));
451 
452  config->SetChoice_list().push_back(sortby_choice);
453 
454  CRef<CTextBox> txt_box(new CTextBox);
455  txt_box->SetName("HistThreshold");
456  txt_box->SetValue(hist_t);
457  txt_box->SetDisplay_name("Heatmap Threshold");
458  txt_box->SetHelp("Display a heatmap when there are more features in this track than the value specificed."
459  " 'None' or '0' means threshold is disabled, and the display is up to 'Rendering Options'");
460  config->SetText_boxes().push_back(txt_box);
461 
462  return config;
463 }
464 
465 
User-defined methods of the data storage class.
Checksum and hash calculation classes.
CAppJobNotification Notification send by CAppJobEventTranslator.
CChecksum – Checksum calculator.
Definition: checksum.hpp:302
CCommentConfig – help config class for holding a set of settings for a comment glyph.
CCommentGlyph – utility class for having comments in graphical glyphs.
static SSorterDescriptor GetSorterDescr()
static SSorterDescriptor GetSorterDescr()
static SSorterDescriptor GetSorterDescr()
static SSorterDescriptor GetSorterDescr()
static SSorterDescriptor GetSorterDescr()
CFeatureTrack –.
static const string & LinkedFeatDisplayValueToStr(ELinkedFeatDisplay linked_feat)
CRef< CSGFeatureDS > m_DS
virtual void x_OnJobCompleted(CAppJobNotification &notify)
virtual void x_LoadSettings(const string &, const TKeyValuePairs &settings)
load the track settings.
virtual void x_UpdateData()
update track content.
const CLayoutGroup::TObjectList & GetChildren() const
void SetCommentGlyphs(const CSeqGlyph::TObjects &objs, CRef< CCommentConfig > config)
@ fNoNavigation
track title won't show navigation controls
@ fNoPin
tooltip is not pinnable
@ fTrack
track title bar
@ fNoSelection
the object can't be selected
int m_Flags
area flags, will need to replace m_Type
CLayoutGroup is a container of CSeqGlyphs (layout objects).
const TObjectList & GetChildren() const
CLayoutGroup inline methods.
string GetTitle() const
get the track title.
TTrackAttrFlags m_Attrs
various track attributes
@ fNavigable
Track has navigation controls.
TModelUnit x_GetTBHeight() const
Get title bar height including margin.
CConstRef< CSeqGraphicConfig > x_GetGlobalConfig() const
Method for getting global configuration from rendering context.
virtual CHTMLActiveArea * InitHTMLActiveArea(TAreaVector *p_areas) const
Initialize the HTML active area for a track.
bool isRmtBased() const
CRef –.
Definition: ncbiobj.hpp:618
CRenderingContext offers the basic context and utility methods for rendering layout objects in featur...
const TSeqRange & GetVisSeqRange() const
static void ParseProfileString(const string &profile_str, TKeyValuePairs &settings)
CSGFeatureDSType.
Definition: feature_ds.hpp:156
CSGFeatureDS.
Definition: feature_ds.hpp:49
void SetRemoteDataType(const string &data_type)
Definition: feature_ds.hpp:198
void SetGraphCacheKey(const string &graph_cache_key)
Definition: feature_ds.hpp:192
void SetSortBy(const string &sortby)
Definition: feature_ds.hpp:184
void SetFilter(const string &filter)
CSGFeatureDS inline method.
Definition: feature_ds.hpp:176
void GetAnnotNames_var(objects::SAnnotSelector &sel, const TSeqRange &range, TAnnotNameTitleMap &names) const
Definition: feature_ds.cpp:522
objects::CBioseq_Handle & GetBioseqHandle(void)
Get the underlying bioseq handle.
void SetDepth(int depth)
Set the annotation selector resolving depth.
void SetAdaptive(bool flag)
static ESubtype SubtypeNameToValue(CTempString sName)
Turn a string into its ESubtype which is NOT necessarily related to the identifier of the enum.
void x_InitHTMLActiveArea(CHTMLActiveArea &area) const
initialize the basic information for a given active area.
Definition: seq_glyph.cpp:380
CRenderingContext * m_Context
the rendering context
Definition: seq_glyph.hpp:346
virtual TModelUnit GetTop() const
Definition: seq_glyph.hpp:599
virtual TModelUnit GetLeft() const
Definition: seq_glyph.hpp:595
vector< CHTMLActiveArea > TAreaVector
Definition: seq_glyph.hpp:84
list< CRef< CSeqGlyph > > TObjects
Definition: seq_glyph.hpp:85
File Description:
const string & GetSortBy() const
const string & GetSource() const
CTextBox –.
Definition: TextBox.hpp:66
CTrackConfigSet –.
static CRef< objects::CChoice > CreateChoice(const string &name, const string &disp_name, const string &curr_val, const string &help, bool optional=false)
Definition: layout_conf.hpp:79
static CRef< objects::CChoiceItem > CreateChoiceItem(const string &name, const string &disp_name, const string &help, const string &legend_txt, bool optional=false)
Definition: layout_conf.hpp:61
CTrackConfig –.
Definition: TrackConfig.hpp:66
CTrackTypeInfo - holds description of a layout track type.
const string & GetDescr() const
const string & GetId() const
virtual string GetExtensionLabel() const
returns a displayable label for this extension ( please capitalize the key words - "My Extension" )
CRef< objects::CTrackConfig > x_GetSettings(const TKeyValuePairs &settings, const CTempTrackProxy *track_proxy, bool is_vcf_track) const
virtual CRef< objects::CTrackConfigSet > GetSettings(const string &profile, const TKeyValuePairs &settings, const CTempTrackProxy *track_proxy) const
virtual void GetMatchedAnnots(const TAnnotMetaDataList &src_annots, const ILayoutTrackFactory::SExtraParams &params, TAnnotNameTitleMap &out_annots) const
virtual const CTrackTypeInfo & GetThisTypeInfo() const
virtual string GetExtensionIdentifier() const
returns the unique human-readable identifier for the extension the id should use lowercase letters se...
virtual TTrackMap CreateTracks(SConstScopedObject &object, ISGDataSourceContext *ds_context, CRenderingContext *r_cntx, const SExtraParams &params=SExtraParams(), const TAnnotMetaDataList &src_annots=TAnnotMetaDataList()) const
create a layout track based on the input objects and extra parameters.
CVarTrack –.
Definition: dbvar_track.hpp:46
virtual void x_LoadSettings(const string &, const TKeyValuePairs &settings) override
load the track settings.
Definition: dbvar_track.cpp:90
virtual void x_UpdateData() override
update track content.
Definition: dbvar_track.cpp:73
static CTrackTypeInfo m_TypeInfo
CVarTrack.
Definition: dbvar_track.hpp:80
virtual CHTMLActiveArea * InitHTMLActiveArea(TAreaVector *p_areas) const override
Initialize the HTML active area for a track.
virtual ~CVarTrack()
Definition: dbvar_track.cpp:63
CVarTrack(CSGFeatureDS *ds, CRenderingContext *r_cntx)
Definition: dbvar_track.cpp:57
virtual const CTrackTypeInfo & GetTypeInfo() const override
Definition: dbvar_track.cpp:67
bool m_ZoomToSee
Definition: dbvar_track.hpp:81
virtual void x_OnJobCompleted(CAppJobNotification &notify) override
Definition: dbvar_track.cpp:97
static void GetMatchedAnnots(const TAnnotMetaDataList &src_annots, const vector< string > &target_annots, const string &annot_type, const string &track_type, TAnnotNameTitleMap &out_annots)
Help function to find matched annotations.
ISGDSManager is seqgraphic data source manage that serves as an data source context.
virtual CIRef< ISGDataSource > GetDS(const string &type, SConstScopedObject &object)=0
Get a seqgraphic data source instance of the specified type.
const_iterator end() const
Definition: map.hpp:152
iterator_bool insert(const value_type &val)
Definition: map.hpp:165
bool empty() const
Definition: map.hpp:149
const_iterator find(const key_type &key) const
Definition: map.hpp:153
struct config config
USING_SCOPE(objects)
string GenerateSignature(const string &title, const string &annot_name, TGi gi, TSeqRange range)
@ eLFD_Default
@ eLFD_Expandable
@ eLFD_ParentHidden
@ eLFD_Hidden
@ eLFD_Packed
static int type
Definition: getdata.c:31
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
Definition: ncbimisc.hpp:815
#define GI_TO(T, gi)
Definition: ncbimisc.hpp:1085
string
Definition: cgiapp.hpp:687
void AddLine(const char *line, size_t len)
Definition: checksum.hpp:609
Uint4 GetChecksum(void) const
Return calculated checksum.
Definition: checksum.hpp:341
#define LOG_POST(message)
This macro is deprecated and it's strongly recomended to move in all projects (except tests) to macro...
Definition: ncbidiag.hpp:226
void Error(CExceptionArgs_Base &args)
Definition: ncbiexpt.hpp:1197
const string & GetMsg(void) const
Get message string.
Definition: ncbiexpt.cpp:461
void Warning(CExceptionArgs_Base &args)
Definition: ncbiexpt.hpp:1191
static bool IsNAA(const string &annot, bool isStrict=false)
check if a given annotation is a named annotation accession[.version][number] when isSctrict == false...
Definition: utils.cpp:796
static objects::SAnnotSelector GetAnnotSelector(TAnnotFlags flags=0)
request an annotation selector for a given type
Definition: utils.cpp:167
GLdouble TModelUnit
Definition: gltypes.hpp:48
int TVPUnit
Definition: gltypes.hpp:47
CGlPoint< TModelUnit > TModelPoint
Definition: gltypes.hpp:51
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,...
TGi GetGiForId(const objects::CSeq_id &id, CScope &scope, EGetIdType flags=0)
Given a Seq-id retrieve the corresponding GI.
Definition: sequence.cpp:668
@ eGetId_ForceGi
return only a gi-based seq-id
Definition: sequence.hpp:99
SAnnotSelector & SetFeatSubtype(TFeatSubtype subtype)
Set feature subtype (also set annotation and feat type)
TObjectType * GetPointer(void) THROWS_NONE
Get pointer,.
Definition: ncbiobj.hpp:998
void Reset(void)
Reset reference object.
Definition: ncbiobj.hpp:773
uint32_t Uint4
4-byte (32-bit) unsigned integer
Definition: ncbitype.h:103
uint16_t Uint2
2-byte (16-bit) unsigned integer
Definition: ncbitype.h:101
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
static bool StringToBool(const CTempString str)
Convert string to bool.
Definition: ncbistr.cpp:2819
static int CompareNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive compare of a substring with another string.
Definition: ncbistr.cpp:219
static int StringToInt(const CTempString str, TStringToNumFlags flags=0, int base=10)
Convert string to int.
Definition: ncbistr.cpp:630
static bool StartsWith(const CTempString str, const CTempString start, ECase use_case=eCase)
Check if a string starts with a specified prefix value.
Definition: ncbistr.hpp:5412
static bool EqualNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive equality of a substring with another string.
Definition: ncbistr.hpp:5353
@ eNocase
Case insensitive compare.
Definition: ncbistr.hpp:1206
Tdata & Set(void)
Assign a value to data member.
range(_Ty, _Ty) -> range< _Ty >
constexpr bool empty(list< Ts... >) noexcept
T bound(T x_, T xlo_, T xhi_)
extra parameter for initializing a track.
bool m_Adaptive
Adaptive/Exact selector.
TAnnots m_Annots
particular annotations the track will be looking at.
string m_Filter
potential track-specific filter.
string m_SortBy
potential track-specific sort_by.
int m_Level
layout level that limits feature retrieving used by annotation selector.
TSeqRange m_Range
The requested range we want to look at.
string m_TrackProfile
Track setting profile for additionial parameters.
string m_Subkey
A subkey for creating feature-specific layout track for a generic layout track type.
bool m_SkipGenuineCheck
Flag indicating if track verification is required.
SAnnotSelector –.
Definition: type.c:6
Modified on Wed Mar 27 11:21:55 2024 by modify_doxy.py rev. 669887