51 static const string kBaseKey =
"GBPlugins.SeqGraphicAggregateFeatureTrack";
54 "A track, showing a predefined set of features.");
68 vector<string> values;
72 result.reserve(values.size());
73 for (
auto &it : values) {
85 vector<string> values;
88 result.reserve(values.size());
89 for (
auto &it : values) {
103 section +=
".Default";
104 section +=
".Subkey.";
106 view =
registry.GetReadView(section);
120 for (
auto &it :
types) {
128 for (
auto &it : subtypes) {
145 title =
"Aggregate Features";
160 section +=
".Default";
161 section +=
".Subkey.";
163 view =
registry.GetReadView(section);
233 feat_track->SetAnnot(iter->first);
234 feat_track->SetFeatTypes(
types);
235 feat_track->SetFeatSubtypes(subtypes);
236 if (!iter->second.empty()) {
237 feat_track->SetTitle(iter->second);
246 tracks[iter->first] = feat_track.
GetPointer();
static const string kTrackName
CAggregateFeatureTrack.
static const string kBaseKey
CAggregateFeatureTrackFactory()
CAggregateFeatureTrackFactory.
virtual string GetExtensionIdentifier() const
returns the unique human-readable identifier for the extension the id should use lowercase letters se...
virtual string GetExtensionLabel() const
returns a displayable label for this extension ( please capitalize the key words - "My Extension" )
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 ¶ms, TAnnotNameTitleMap &out_annots) const
virtual TTrackMap CreateTracks(SConstScopedObject &object, ISGDataSourceContext *ds_context, CRenderingContext *r_cntx, const SExtraParams ¶ms=SExtraParams(), const TAnnotMetaDataList &src_annots=TAnnotMetaDataList()) const
Create a biological region track based on the input object and extra parameters.
CAggregateFeatureTrack - combines a set of features into a single track.
static CTrackTypeInfo m_TypeInfo
std::vector< objects::CSeqFeatData::E_Choice > TTypeVec
void SetFeatSubtypes(const TSubtypeVec &subtypes)
static vector< string > GetSubtypeListAsString(const std::string &subkey)
virtual string GetFullTitle() const
get a more meaningful title.
static TTypeMap x_GetFeatTypeMap()
Initializes the feature name to type map.
set< objects::CSeqFeatData::ESubtype > m_subtypes
CAggregateFeatureTrack(CSGFeatureDS *ds, CRenderingContext *r_cntx)
std::map< std::string, objects::CSeqFeatData::E_Choice > TTypeMap
static TSubtypeVec GetSubtypeList(const std::string &subkey)
virtual void GetFeatSubtypes(set< objects::CSeqFeatData::ESubtype > &subtypes) const
static TTypeVec GetTypeList(const std::string &subkey)
static void x_GetSubkeyStringVec(const string &subkey, const string &field, vector< string > &values)
Reads the string vector for the specified subkey from the registry.
virtual const CTrackTypeInfo & GetTypeInfo() const
std::vector< objects::CSeqFeatData::ESubtype > TSubtypeVec
void SetFeatTypes(const TTypeVec &types)
CRef< objects::CTrackConfig > x_GetSettings(const TKeyValuePairs &settings, const CTempTrackProxy *track_proxy, bool is_intron_track) const
CFeatureTrack::ELayout m_DefaultLayout
ELinkedFeatDisplay m_DefaultLinkedFeat
objects::SAnnotSelector m_FeatSel
@ eLayout_ExpandedLayered
show all features with layered layout
ELinkedFeatDisplay m_LinkedFeat
static CGuiRegistry & GetInstance()
access the application-wide singleton
string GetTitle() const
get the track title.
class CRegistryReadView provides a nested hierarchical view at a particular key.
void GetStringVec(const string &key, vector< string > &val) const
CRenderingContext offers the basic context and utility methods for rendering layout objects in featur...
void SetSortBy(const string &sortby)
void SetFilter(const string &filter)
CSGFeatureDS inline method.
void SetGraphLevels(const string &annot)
void SetDepth(int depth)
Set the annotation selector resolving depth.
void SetAdaptive(bool flag)
@ eSubtype_bad
These no longer need to match the FEATDEF values in the C toolkit's objfdef.h.
static ESubtype SubtypeNameToValue(CTempString sName)
Turn a string into its ESubtype which is NOT necessarily related to the identifier of the enum.
CTrackTypeInfo - holds description of a layout track type.
const string & GetDescr() const
const string & GetId() const
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.
iterator_bool insert(const value_type &val)
container_type::value_type value_type
iterator_bool insert(const value_type &val)
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
static bool IsUnnamed(const string &annot)
check if a given annotation is a unnamed annotation.
TObjectType * GetPointer(void) THROWS_NONE
Get pointer,.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
static string & ToLower(string &str)
Convert string to lower case – string& version.
Tdata & Set(void)
Assign a value to data member.
@ e_Het
cofactor, prosthetic grp, etc, bound to seq
@ e_Region
named region (globin locus)
@ e_Seq
to annotate origin from another seq
@ e_Txinit
transcription initiation
@ e_Num
a numbering system
@ e_Pub
publication applies to this seq
@ e_User
user defined structure
@ e_Rsite
restriction site (for maps really)
@ e_Comment
just a comment
@ e_Non_std_residue
non-standard residue here in seq
void GetSubtypesForType(set< objects::CSeqFeatData::ESubtype > &subtypes, objects::CSeqFeatData::E_Choice feat)
const struct ncbi::grid::netcache::search::fields::SUBKEY subkey
static const struct type types[]