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/assembly__list__panel_8cpp_source.html below:

NCBI C++ ToolKit: src/gui/widgets/loaders/assembly_list_panel.cpp Source File

56 #include <wx/stattext.h> 57 #include <wx/statbox.h> 59 #include <wx/bitmap.h> 60 #include <wx/msgdlg.h> 61 #include <wx/radiobut.h> 103 

wxPanel::Create( parent,

id

, pos,

size

, style );

108

GetSizer()->SetSizeHints(

this

);

140

wxBoxSizer* itemBoxSizer2 =

new

wxBoxSizer(wxVERTICAL);

141

itemPanel1->SetSizer(itemBoxSizer2);

143

wxStaticText* itemStaticText3 =

new

wxStaticText( itemPanel1, wxID_STATIC,

_

(

"Enter a search term , then select assembly(ies) from the list."

), wxDefaultPosition, wxDefaultSize, 0 );

144

itemStaticText3->SetFont(wxFont(wxNORMAL_FONT->GetPointSize(), wxNORMAL_FONT->GetFamily(), wxNORMAL_FONT->GetStyle(), wxFONTWEIGHT_BOLD, wxNORMAL_FONT->GetUnderlined(), wxNORMAL_FONT->GetFaceName()));

145

itemBoxSizer2->Add(itemStaticText3, 0, wxALIGN_LEFT|wxALL, 5);

147

wxBoxSizer* itemBoxSizer4 =

new

wxBoxSizer(wxHORIZONTAL);

148

itemBoxSizer2->Add(itemBoxSizer4, 0, wxALIGN_LEFT|wxALL, 5);

150

wxStaticText* itemStaticText5 =

new

wxStaticText( itemPanel1, wxID_STATIC,

_

(

"Search term:"

), wxDefaultPosition, wxDefaultSize, 0 );

151

itemBoxSizer4->Add(itemStaticText5, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

155  m_Term

->SetToolTip(

_

(

" \"A valid search term can be one of the following:\n 1. Organism keyword, e.g. human, zebra fish, zebra*\n 2. Taxonomy id, e.g. 9606, 10116\n 3. Assembly name, e.g. hg19, GRCH37, NCBI*\n 4. Sequence accession, e.g. NC_000001.10, nt_077402.2\"\n "

));

156

itemBoxSizer4->Add(

m_Term

, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

158

wxButton* itemButton7 =

new

wxButton( itemPanel1,

ID_BUTTON4

,

_

(

"Find Assemblies"

), wxDefaultPosition, wxDefaultSize, 0 );

159

itemButton7->SetDefault();

160

itemBoxSizer4->Add(itemButton7, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

162

wxStaticBox* itemStaticBoxSizer8Static =

new

wxStaticBox(itemPanel1,

wxID_ANY

,

_

(

"Found Assemblies"

));

163

wxStaticBoxSizer* itemStaticBoxSizer8 =

new

wxStaticBoxSizer(itemStaticBoxSizer8Static, wxHORIZONTAL);

164

itemBoxSizer2->Add(itemStaticBoxSizer8, 1, wxGROW|wxALL, 5);

167

itemStaticBoxSizer8->Add(

m_ItemList

, 1, wxGROW|wxALL, 5);

169

wxStaticBox* itemStaticBoxSizer10Static =

new

wxStaticBox(itemPanel1,

wxID_ANY

,

_

(

"Release type"

));

170

wxStaticBoxSizer* itemStaticBoxSizer10 =

new

wxStaticBoxSizer(itemStaticBoxSizer10Static, wxHORIZONTAL);

171

itemBoxSizer2->Add(itemStaticBoxSizer10, 0, wxALIGN_LEFT|wxALL, 5);

173  m_ReleaseTypeAll

=

new

wxRadioButton( itemPanel1,

ID_ALLBUTTON

,

_

(

"All"

), wxDefaultPosition, wxSize(itemPanel1->ConvertDialogToPixels(wxSize(53, -1)).x, -1), wxRB_GROUP );

175

itemStaticBoxSizer10->Add(

m_ReleaseTypeAll

, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

177  m_ReleaseTypeRefSeq

=

new

wxRadioButton( itemPanel1,

ID_REFSEQBUTTON

,

_

(

"RefSeq"

), wxDefaultPosition, wxSize(itemPanel1->ConvertDialogToPixels(wxSize(53, -1)).x, -1), 0 );

190  static bool

autoCompleteSupported =

true

;

191  if

(autoCompleteSupported) {

193

autoCompleteSupported =

false

;

194  LOG_POST

(

Error

<<

"The platform doesn't support text autocomplete"

);

198  delete

textCompleter;

236

vector<string> assms;

237

vector<int> rows_selected;

239  ITERATE

(vector<int>, r_iter, rows_selected) {

240

assms.push_back(

m_Assms

[*r_iter]);

248  string

& description)

const 267

other_names +=

"; "

;

269  size_t

pos = name_iter->find_first_of(

":"

);

270  if

(pos != string::npos) {

274  if

( !other_names.empty() ) {

275

name +=

" ("

+ other_names +

")"

;

290

wxMessageBox(

wxT

(

"Genome List is empty!"

),

291  wxT

(

"Assembly selection - no selection"

),

292

wxOK | wxICON_ERROR,

this

);

297

wxMessageBox(

wxT

(

"Please select one or more assemblies!"

),

298  wxT

(

"Assembly selection - no selection"

),

299

wxOK | wxICON_ERROR,

this

);

302

wxMessageBox(

wxT

(

"Please select one assembly!"

),

303  wxT

(

"Assembly selection - no selection"

),

304

wxOK | wxICON_ERROR,

this

);

394  string

release_str =

"refseq"

;

396

release_str =

"genbank"

;

398

CDL_AssmInfo::TAssemblies::iterator iter = items.begin();

399  while

(iter != items.end()) {

400  if

( !(*iter)->IsSetRelease_type() ||

401

(*iter)->GetRelease_type() != release_str) {

402

iter = items.erase(iter);

411  m_Assms

.push_back((*iter)->GetAccession());

430  string

name = assm.

GetName

();

438

other_names +=

"; "

;

440  size_t

pos = name_iter->find_first_of(

":"

);

441  if

(pos != string::npos) {

445  if

( !other_names.empty() ) {

446

name +=

" ("

+ other_names +

")"

;

480  if

(items.size() == 1) {

536  if

(

m_Term

->GetValue().IsEmpty()) {

537

wxMessageBox(

wxT

(

"Please fill in the search term!"

),

538  wxT

(

"Assembly query input - invalid input"

),

539

wxOK | wxICON_ERROR,

this

);

557

std::exception_ptr excp;

560  LOG_POST

(

Info

<<

"Retrieve assembly information for: "

<< term);

567

excp = std::current_exception();

591

excp = std::current_exception();

595

std::rethrow_exception(excp);

609  catch

(

const

exception&) {

620

errMsg =

"Can't find any assembly related to \""

+

m_SearchingFor

+

"\""

;

624

,

"Search Assemblies"

));

User-defined methods of the data storage class.

User-defined methods of the data storage class.

static CStringHistory s_History(50, "Dialogs.AssemblyListPanel")

static const char * kReleaseTypeTag

static CRef< objects::CDL_AssmInfo > GetAssms_Term(const string &term, const string &release_type=NcbiEmptyString, ICanceled *cancel=0)

static CRef< objects::CDL_AssmInfo > GetAssms_Gi(TGi gi, const string &release_type=NcbiEmptyString)

void SaveSettings() const

wxRadioButton * m_ReleaseTypeRefSeq

wxRadioButton * m_ReleaseTypeAll

void SetSearchTerm(const string &term)

bool Create(wxWindow *parent, wxWindowID id=ID_CASSEMBLYLISTPANEL, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(266, 184), long style=wxWANTS_CHARS|wxTAB_TRAVERSAL)

void OnGenbankbuttonSelected(wxCommandEvent &event)

wxEVT_COMMAND_RADIOBUTTON_SELECTED event handler for ID_GENBANKBUTTON

wxIcon GetIconResource(const wxString &name)

Retrieves icon resources.

wxBitmap GetBitmapResource(const wxString &name)

Retrieves bitmap resources.

void x_SetTextCompleter(wxTextCompleter *textCompleter)

void SetMultiSelection(bool flag)

objects::CDL_AssmInfo::TAssemblies m_OrigItems

void OnAllbuttonSelected(wxCommandEvent &event)

wxEVT_COMMAND_RADIOBUTTON_SELECTED event handler for ID_ALLBUTTON

void OnFindGenomes(wxCommandEvent &event)

wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON4

void SetRegistryPath(const string &path)

vector< string > GetSelectedAssemblies() const

Get accessions of all selected assemblies.

void GetAssmNameAndDesc(const string &accession, string &name, string &description) const

Get the name and (if available) description for an accession.

string GetSearchTerm() const

std::unique_ptr< async_job > m_Future

void x_UpdateSearchTerm()

void x_LoadTableSettings()

void SetDescr(const wxString &descr)

CAutoCompleteTextCtrl * m_Term

void x_ShowStatus(const string &status)

wxRadioButton * m_ReleaseTypeGenBank

void SetMainTitle(const wxString &title)

static bool ShowToolTips()

CwxTableListCtrl * m_ItemList

void OnFindEnter(wxCommandEvent &event)

wxEVT_COMMAND_TEXT_ENTER event handler for ID_TEXTCTRL7

void OnRefseqbuttonSelected(wxCommandEvent &event)

wxEVT_COMMAND_RADIOBUTTON_SELECTED event handler for ID_REFSEQBUTTON

bool m_MultiSelection

indicates if multiple selections are allowed.

bool AutoComplete(wxTextCompleter *completer)

CRegistryWriteView GetWriteView(const string &section)

get a read-write view at a particular level.

static CGuiRegistry & GetInstance()

access the application-wide singleton

CRegistryReadView GetReadView(const string &section) const

get a read-only view at a particular level.

class CRegistryReadView provides a nested hierarchical view at a particular key.

int GetInt(const string &key, int default_val=0) const

access a named key at this level, with no recursion

void Set(const string &key, int val)

access a named key at this level, with no recursion

void AddString(const wxString &str)

wxTextCompleter * CreateCompleter()

CwxTextTableModel - very simple model for storing SMALL numbers fo strings.

virtual void Init(int n_cols, int n_rows)

virtual void SetStringValueAt(int row, int col, const wxString &value)

CwxTableListCtrl - generic wxListCtrl-based Table Control.

IwxTableModel * GetModel() const

void LoadTableSettings(const CRegistryReadView &view, bool byName=false)

wxArrayInt GetDataRowsSelected() const

void SaveTableSettings(CRegistryWriteView &view, bool saveSorting=true) const

void SetModel(IwxTableModel *data_model, bool own=false)

Interface for testing cancellation request in a long lasting operation.

virtual int GetNumColumns() const =0

Returns the number of columns in the model.

static DLIST_TYPE *DLIST_NAME() first(DLIST_LIST_TYPE *list)

static const column_t columns[]

#define ITERATE(Type, Var, Cont)

ITERATE macro to sequence through container elements.

#define LOG_POST(message)

This macro is deprecated and it's strongly recomended to move in all projects (except tests) to macro...

void Error(CExceptionArgs_Base &args)

const string & GetMsg(void) const

Get message string.

void Info(CExceptionArgs_Base &args)

CSeq_id & Set(const CTempString &the_id, TParseFlags flags=fParse_AnyRaw)

Reassign based on flat specifications; arguments interpreted as with constructors.

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,...

@ eGetId_ForceGi

return only a gi-based seq-id

static CRef< CObjectManager > GetInstance(void)

Return the existing object manager or create one.

CBioseq_Handle GetBioseqHandle(const CSeq_id &id)

Get bioseq handle by seq-id.

void AddDefaults(TPriority pri=kPriority_Default)

Add default data loaders from object manager.

const CSeq_id_Handle & GetSeq_id_Handle(void) const

Get handle of id used to obtain this bioseq handle.

#define END_NCBI_SCOPE

End previously defined NCBI scope.

#define BEGIN_NCBI_SCOPE

Define ncbi namespace.

virtual bool IsCanceled(void) const =0

static string TruncateSpaces(const string &str, ETrunc where=eTrunc_Both)

Truncate whitespace in a string.

bool CanGetOrganism(void) const

Check if it is safe to call GetOrganism method.

list< string > TOther_names

const TRelease_date & GetRelease_date(void) const

Get the Release_date member data.

bool CanGetRelease_type(void) const

Check if it is safe to call GetRelease_type method.

const TClass & GetClass(void) const

Get the Class member data.

const TOther_names & GetOther_names(void) const

Get the Other_names member data.

const TDescr & GetDescr(void) const

Get the Descr member data.

bool CanGetOther_names(void) const

Check if it is safe to call GetOther_names method.

const TAccession & GetAccession(void) const

Get the Accession member data.

const TName & GetName(void) const

Get the Name member data.

bool CanGetClass(void) const

Check if it is safe to call GetClass method.

list< CRef< CDL_Assembly > > TAssemblies

const TRelease_type & GetRelease_type(void) const

Get the Release_type member data.

const TOrganism & GetOrganism(void) const

Get the Organism member data.

const TAssemblies & GetAssemblies(void) const

Get the variant data.

bool CanGetDescr(void) const

Check if it is safe to call GetDescr method.

bool CanGetRelease_date(void) const

Check if it is safe to call GetRelease_date method.

job_function_traits< _Fty >::future job_async(const _Fty &_Fnarg, const string &descr)

static void text(MDB_val *v)

const struct ncbi::grid::netcache::search::fields::SIZE size

#define row(bind, expected)

wxString ToWxString(const string &s)

string ToStdString(const wxString &s)


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