: m_IsSingle(
false), m_CmdProcessor()
180: m_IsSingle(
false), m_CmdProcessor(), m_SubmissionOk(
false), m_DataIsSaved(
false), m_SubmissionErrors(
"")
194wxScrolledWindow::Create( parent,
id, pos,
size, style );
199GetSizer()->SetSizeHints(
this);
204wxClientDC dc(
this);
205SetScrollRate(dc.GetCharWidth(),dc.GetCharHeight());
277wxBoxSizer* itemBoxSizer2 =
newwxBoxSizer(wxVERTICAL);
278itemScrolledWindow1->SetSizer(itemBoxSizer2);
280 m_Status=
newwxStaticText( itemScrolledWindow1, wxID_STATIC, wxEmptyString, wxDefaultPosition, wxSize(550, -1), wxALIGN_RIGHT|wxST_NO_AUTORESIZE );
281 m_Status->SetFont(wxFont(14, wxFONTFAMILY_SWISS, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD,
false,
wxT(
"Tahoma")));
282itemBoxSizer2->Add(
m_Status, 0, wxALIGN_LEFT|wxALL, 5);
284wxFlexGridSizer* itemFlexGridSizer4 =
newwxFlexGridSizer(0, 4, 0, 0);
285itemBoxSizer2->Add(itemFlexGridSizer4, 0, wxALIGN_LEFT|wxALL, 5);
287 m_Book=
newwxNotebook( itemScrolledWindow1,
ID_NOTEBOOK, wxDefaultPosition, wxDefaultSize, wxBK_DEFAULT );
289itemBoxSizer2->Add(
m_Book, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
291 m_SequenceCount=
newwxStaticText( itemScrolledWindow1, wxID_STATIC, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxALIGN_CENTRE );
292itemBoxSizer2->Add(
m_SequenceCount, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
294wxBoxSizer* itemBoxSizer7 =
newwxBoxSizer(wxHORIZONTAL);
295itemBoxSizer2->Add(itemBoxSizer7, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
297wxButton* itemButton8 =
newwxButton( itemScrolledWindow1,
ID_BUTTON17,
_(
"Open Existing Submission"), wxDefaultPosition, wxDefaultSize, 0 );
298itemBoxSizer7->Add(itemButton8, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
300wxButton* itemButton9 =
newwxButton( itemScrolledWindow1,
ID_ADD_SEQUENCE_BTN,
_(
"Add Sequences"), wxDefaultPosition, wxDefaultSize, 0 );
301itemBoxSizer7->Add(itemButton9, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
311 m_VectorTrimBtn=
newwxButton( itemScrolledWindow1,
ID_BUTTON13,
_(
"Vector Trim Tool"), wxDefaultPosition, wxDefaultSize, 0 );
313itemBoxSizer7->Add(
m_VectorTrimBtn, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
315wxBoxSizer* itemBoxSizer13 =
newwxBoxSizer(wxHORIZONTAL);
316itemBoxSizer2->Add(itemBoxSizer13, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
318 m_PrevBtn=
newwxButton( itemScrolledWindow1,
ID_PREV_BTN,
_(
"Prev"), wxDefaultPosition, wxDefaultSize, 0 );
320itemBoxSizer13->Add(
m_PrevBtn, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
322 m_NextBtn=
newwxButton( itemScrolledWindow1,
ID_NEXT_BTN,
_(
"Next"), wxDefaultPosition, wxDefaultSize, 0 );
324itemBoxSizer13->Add(
m_NextBtn, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
329wxStaticText* itemStaticText17 =
newwxStaticText( itemScrolledWindow1, wxID_STATIC,
_(
"*"), wxDefaultPosition, wxDefaultSize, 0 );
330itemStaticText17->SetForegroundColour(wxColour(255, 0, 0));
333wxStaticText* itemStaticText18 =
newwxStaticText( itemScrolledWindow1, wxID_STATIC,
_(
"Indicates required information has not been provided"), wxDefaultPosition, wxDefaultSize, 0 );
336wxBoxSizer* itemBoxSizer19 =
newwxBoxSizer(wxHORIZONTAL);
337itemBoxSizer2->Add(itemBoxSizer19, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
340itemBoxSizer19->Add(
m_FlatfileButton, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
343itemBoxSizer19->Add(
m_TaxonomyButton, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
346itemBoxSizer19->Add(
m_ValidateButton, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
348wxButton* itemButton23 =
newwxButton( itemScrolledWindow1,
ID_SAVE_BTN,
_(
"Save"), wxDefaultPosition, wxDefaultSize, 0 );
349itemBoxSizer19->Add(itemButton23, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
351wxBoxSizer* itemBoxSizer24 =
newwxBoxSizer(wxHORIZONTAL);
352itemBoxSizer2->Add(itemBoxSizer24, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
354 m_StartNewBtn=
newwxButton( itemScrolledWindow1,
ID_START_NEW,
_(
"Start New Submission"), wxDefaultPosition, wxDefaultSize, 0 );
355itemBoxSizer24->Add(
m_StartNewBtn, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
376 returnwxScrolledWindow::Layout();
406 switch(wizard_type) {
447vector<CTableFieldCommandConverter*> converter_list;
449 switch(wizard_type) {
461 boolany_data =
false;
462 for(
size_t i= 0;
i< converter_list.size();
i++) {
464 ITERATE(objects::CSeq_table::TColumns, cit,
table->GetColumns()) {
474 for(
size_t i= 0;
i< converter_list.size();
i++) {
477 cmd->AddCommand(*subcmd);
482 for(
size_t i= 0;
i< converter_list.size();
i++) {
483 deleteconverter_list[
i];
498 stringfirst_val =
"linear";
499 if(col->IsSetData() && col->GetData().GetString().size() > 0) {
500first_val = col->GetData().GetString().front();
502first_val =
"linear";
522must_choose =
false;
547converter,
false,
false,
"");
568 m_DBLinkUrls.push_back(
"https://dsubmit.ncbi.nlm.nih.gov/subs/SUB002235/submitter");
571 m_DBLinkUrls.push_back(
"https://trace.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=announcement");
574 m_DBLinkUrls.push_back(
"https://dsubmit.ncbi.nlm.nih.gov/subs/SUB002236/submitter");
612 if(
set&&
set->IsSetSeq_set() &&
set->GetSeq_set().
size() >= 500) {
620 stringtitle =
m_SeqSubmit->GetSub().GetCit().GetDescr();
621 if(
NStr::Find(title,
"454") != string::npos
622||
NStr::Find(title,
"Complete Genomics") != string::npos
623||
NStr::Find(title,
"Helicos") != string::npos
624||
NStr::Find(title,
"Illumina") != string::npos
625||
NStr::Find(title,
"IonTorrent") != string::npos
626||
NStr::Find(title,
"PacBio") != string::npos
627||
NStr::Find(title,
"Pacific Biosciences") != string::npos
628||
NStr::Find(title,
"SOLiD") != string::npos
629||
NStr::Find(title,
"pyrosequencing") != string::npos
630||
NStr::Find(title,
"HiSeq") != string::npos
631||
NStr::Find(title,
"transcriptome") != string::npos
632||
NStr::Find(title,
"solexa") != string::npos
633||
NStr::Find(title,
"deep sequencing") != string::npos
634||
NStr::Find(title,
"deep-sequencing") != string::npos
635||
NStr::Find(title,
"transcriptom") != string::npos
636||
NStr::Find(title,
"next-gen") != string::npos
637||
NStr::Find(title,
"RNA-Seq") != string::npos
638||
NStr::Find(title,
"RNASeq") != string::npos
639||
NStr::Find(title,
"RNA Seq") != string::npos
640||
NStr::Find(title,
"high-throughput") != string::npos
641||
NStr::Find(title,
"high throughput") != string::npos
642||
NStr::Find(title,
"metagenom") != string::npos
643||
NStr::Find(title,
"assembl") != string::npos
644||
NStr::Find(title,
"raw seq") != string::npos
645||
NStr::Find(title,
"next gen") != string::npos) {
673objects::CBioseq_CI b_iter(entry, objects::CSeq_inst::eMol_na);
674 for( ; b_iter && !found; ++b_iter ) {
675objects::CSeqdesc_CI it (*b_iter, objects::CSeqdesc::e_Source);
676 while(it && !found) {
677 if(it->GetSource().IsSetSubtype()) {
678 ITERATE(objects::CBioSource::TSubtype, sit, it->GetSource().GetSubtype()) {
679 if((*sit)->IsSetSubtype()
680&& (*sit)->GetSubtype() == objects::CSubSource::eSubtype_other
681&& (*sit)->IsSetName()) {
682 stringnote = (*sit)->GetName();
684 while(pos != string::npos && !found) {
694note = note.substr(pos + 7);
712objects::CSeqdesc_CI it (entry, objects::CSeqdesc::e_User);
730 for(objects::CSeqdesc_CI desc_ci( entry, objects::CSeqdesc::e_User);
733 constobjects::CUser_object& u = desc_ci->GetUser();
737new_user->Assign (u);
738new_desc->SetUser(*new_user);
739objects::CUser_field& new_field = new_user->SetField(field_name);
740new_field.SetData().SetStr(
value);
742 cmd->AddCommand (*ecmd);
749new_desc->SetUser(*new_user);
750objects::CUser_field& new_field = new_user->SetField(field_name);
751new_field.SetData().SetStr(
value);
761objects::CSeqdesc_CI it (entry, objects::CSeqdesc::e_User);
777objects::CSeqdesc_CI it (
m_TopSeqEntry, objects::CSeqdesc::e_User);
793objects::CSeqdesc_CI it (
m_TopSeqEntry, objects::CSeqdesc::e_User);
812objects::CSeqdesc_CI it (entry, objects::CSeqdesc::e_User);
837 switch(wizard_type) {
845 return "Uncultured Samples";
848 return "rRNA-ITS-IGS sequences";
854 return "Intergenic Spacer (IGS) sequences";
857 return "Microsatellite sequences";
860 return "D-loops and control regions";
904 stringqual_report =
"";
914 for(
int row= 0;
row< values_table->GetNum_rows();
row++) {
923qual_report +=
"; ";
925qual_report += id_label +
":"+ problems->GetData().GetString()[
row];
934qual_report =
"No Source Qualifier Problems Found";
950 boolhas_problem =
false;
951 boolfeatures_ok =
false;
964vector<string> problem_strings;
967problem_strings.push_back(*it);
971 ITERATE(vector<string>, it, problem_strings) {
1052 const CObject* ptr = it->object.GetPointer();
1055 constobjects::CSeq_entry* seqEntry =
dynamic_cast<constobjects::CSeq_entry*
>(ptr);
1056objects::CSeq_entry_Handle seh;
1058seh = it->scope->GetSeq_entryHandle (*seqEntry);
1060 constobjects::CSeq_submit* seqsubmit =
dynamic_cast<constobjects::CSeq_submit*
>(ptr);
1062 m_SeqSubmit=
const_cast<objects::CSeq_submit*
>(seqsubmit);
1063 if(seqsubmit->IsEntrys()) {
1064seh = it->scope->GetSeq_entryHandle(*(seqsubmit->GetData().GetEntrys().front()));
1067 constobjects::CSeq_id* seqid =
dynamic_cast<constobjects::CSeq_id*
>(ptr);
1069objects::CBioseq_Handle bsh = it->scope->GetBioseqHandle(*seqid);
if(bsh) {
1070seh = bsh.GetSeq_entry_Handle();
1085 returnwxPanel::TransferDataToWindow();
1136 returnwxNullBitmap;
1156 size_tnum_pages =
m_Book->GetPageCount();
1157 if(num_pages < 2) {
1161 intselection =
m_Book->GetSelection();
1162 if(selection < num_pages - 1 && m_IntroPanel != NULL && m_IntroPanel->IsComplete()) {
1167 if(selection > 0) {
1178 boolany_seq =
false;
1179 boolmulti_seq =
false;
1263 if(!
ispunct(last_char.c_str()[0])) {
1276 m_Status->SetLabel(
"Submission is ready!");
1277 m_Status->SetForegroundColour(*wxBLACK);
1279 m_Status->SetLabel(
wxT(
"Submission is incomplete!"));
1280 m_Status->SetForegroundColour(*wxRED);
1287objects::CSeqdesc_CI it(
m_TopSeqEntry, objects::CSeqdesc::e_Pub);
1289 if(it->GetPub().IsSetPub()
1290&& it->GetPub().GetPub().Get().size() > 0
1291&& it->GetPub().GetPub().Get().front()->IsGen()) {
1292 constobjects::CCit_gen& orig_gen = it->GetPub().GetPub().Get().front()->GetGen();
1293 if(orig_gen.IsSetCit() &&
NStr::Equal(orig_gen.GetCit(),
"Unpublished")) {
1320seq_submit->SetData().SetEntrys().push_back(entry);
1335 gen->Assign(orig_citsub->GetPub().GetPub().Get().front()->GetGen());
1348new_pub->SetGen(*new_gen);
1349new_desc->SetPub().SetPub().Set().push_back(new_pub);
1355 cmd->AddCommand(*ecmd);
1359 cmd->AddCommand(*ecmd);
1363 if(new_gen->IsSetDate()) {
1365new_create_desc->SetCreate_date().Assign(new_gen->GetDate());
1366objects::CSeqdesc_CI it(
m_TopSeqEntry, objects::CSeqdesc::e_Create_date);
1369 cmd->AddCommand(*ecmd);
1373 cmd->AddCommand(*ecmd);
1406 boolok_to_bulk_edit =
true;
1410 for(
size_t i= 1;
i<
table->GetColumns().
size() && ok_to_bulk_edit;
i++) {
1411 stringtitle =
table->GetColumns()[
i]->GetHeader().GetTitle();
1413ok_to_bulk_edit =
false;
1417 returnok_to_bulk_edit;
1425 if(dlg.ShowModal() == wxID_OK) {
1435vector<string> qual_names;
1436qual_names.push_back(
"taxname");
1437qual_names.push_back(
"clone");
1440 if(!src_table || src_table->GetNum_rows() == 0) {
1445vector<string> vals;
1446 for(
int i= 0;
i< src_table->GetNum_rows();
i++) {
1447 stringrow_val =
"";
1448 if(tax_col && tax_col->GetData().GetSize() >
i) {
1449row_val += tax_col->GetData().GetString()[
i];
1451 if(clone_col && clone_col->GetData().GetSize() >
i) {
1452row_val += clone_col->GetData().GetString()[
i];
1458vals.push_back(row_val);
1464 if(sorted_vals.size() > 0) {
1474vector<size_t> lens;
1477 ITERATE(objects::CSeqTable_column::TData::TId, it, col->GetData().GetId()) {
1478objects::CBioseq_Handle bsh =
m_TopSeqEntry.GetScope().GetBioseqHandle(**it);
1479lens.push_back(bsh.GetBioseqLength());
1488feat->SetData().SetImp().SetKey(
"repeat_region");
1489feat->SetQual().push_back(
CRef<objects::CGb_qual>(
newobjects::CGb_qual(
"satellite",
"microsatellite")));
1498 deletetmp_converter;
1521wxWindow* main_window =
NULL;
1526dlg->
Show(
true);
1542 stringmessage =
"Do you want to clear "+
GetWizardTypeName(prev_wizard_type) +
"-specific data?";
1543wxMessageDialog dlg(
this,
ToWxString(message),
wxT(
"Clear Data"), wxYES_NO|wxCANCEL|wxYES_DEFAULT);
1544 intanswer = dlg.ShowModal();
1545 if(answer == wxID_CANCEL) {
1546 returnprev_wizard_type;
1547}
else if(answer == wxID_NO) {
1561 if(all_same && any_missing) {
1594 switch(wizard_type) {
1620||
m_TopSeqEntry.GetSet().GetClass() == objects::CBioseq_set::eClass_not_set)) {
1624new_set->Assign(*(beh.GetCompleteBioseq_set()));
1625new_set->SetClass(objects::CBioseq_set::eClass_genbank);
1627 cmd->AddCommand(*set_cmd);
1649objects::CBioseq_set::TClass old_class = objects::CBioseq_set::eClass_not_set;
1653objects::CBioseq_set::TClass new_class = objects::CBioseq_set::eClass_not_set;
1655 if(
NStr::Find(new_val,
"Population") != string::npos) {
1656new_class = objects::CBioseq_set::eClass_pop_set;
1657}
else if(
NStr::Find(new_val,
"Phylogenetic") != string::npos) {
1658new_class = objects::CBioseq_set::eClass_phy_set;
1659}
else if(
NStr::Find(new_val,
"Mutation") != string::npos) {
1660new_class = objects::CBioseq_set::eClass_mut_set;
1661}
else if(
NStr::Find(new_val,
"Environmental set") != string::npos) {
1662new_class = objects::CBioseq_set::eClass_eco_set;
1663}
else if(
NStr::Find(new_val,
"Batch") != string::npos) {
1664new_class = objects::CBioseq_set::eClass_genbank;
1667 if(new_class != old_class && new_class != objects::CBioseq_set::eClass_not_set) {
1671new_set->Assign(*(beh.GetCompleteBioseq_set()));
1672new_set->SetClass(new_class);
1713vector<string> fields;
1714fields.push_back(field_name);
1772wxOK | wxCANCEL,
this) == wxOK) {
1776wxMessageBox(
_(
"No features found!"),
wxT(
"Error"),
1777wxOK | wxICON_ERROR,
this);
1807validator::CValidator validator(*objmgr);
1808 unsigned intoptions = validator::CValidator::eVal_validate_id_set
1809| validator::CValidator::eVal_use_entrez;
1812wxMessageBox(
wxT(
"File has been saved, but validation errors were found. Please try to correct these before submitting."),
wxT(
"Error"),
1813wxOK | wxICON_ERROR,
this);
1819 const string kNotReadyForSubmission=
"Warning: This submission is not ready to be submitted to GenBank. Do not submit this file until all required information is provided.";
1843wxOK | wxCANCEL | wxICON_WARNING,
this) == wxCANCEL) {
1854 wxT(
"ASN.1 files (")+extensions +
wxT(
")|") + extensions +
wxT(
"|") +
1856wxFD_SAVE|wxFD_OVERWRITE_PROMPT);
1858 if(asn_save_file.ShowModal() == wxID_OK)
1860wxString path = asn_save_file.GetPath();
1861wxString name = asn_save_file.GetFilename();
1868wxMessageBox(
wxT(
"Please, select file name"),
wxT(
"Error"),
1869wxOK | wxICON_ERROR,
this);
1873 if(name.Find(wxUniChar(
'.')) == wxNOT_FOUND)
1875path +=
wxT(
".sqn");
1876name +=
wxT(
".sqn");
1883wxMessageBox(
wxT(
"Cannot open file ")+name,
wxT(
"Error"),
1884wxOK | wxICON_ERROR,
this);
1920 if(dlg.ShowModal() == wxID_OK) {
1937vector<string> format_ids;
1938format_ids.push_back(
"file_loader_fasta");
1939format_ids.push_back(
"file_loader_asn");
1940format_ids.push_back(
"file_loader_text_align");
1941fileManager->LoadFormats(format_ids);
1943vector<CIRef<IOpenObjectsPanelClient> > loadManagers;
1947dlg.SetSize(710, 480);
1952 if(dlg.ShowModal() == wxID_OK) {
1954 if(!object_loader) {
1955wxMessageBox(
wxT(
"Failed to get object loader"),
wxT(
"Error"),
1956wxOK | wxICON_ERROR);
1971 boolhas_nuc =
false;
1972 boolhas_prot =
false;
1973 boolsuccess =
true;
1975entry_to_add->SetSet().SetClass(objects::CBioseq_set::eClass_genbank);
1978 const CObject& ptr = obj_it->GetObject();
1979 constobjects::CSeq_entry* entry =
dynamic_cast<constobjects::CSeq_entry*
>(&ptr);
1982add->Assign(*entry);
1983entry_to_add->SetSet().SetSeq_set().push_back(add);
1985 constobjects::CSeq_submit* submit =
dynamic_cast<constobjects::CSeq_submit*
>(&ptr);
1987 ITERATE(objects::CSeq_submit::TData::TEntrys, sit, submit->GetData().GetEntrys()) {
1990entry_to_add->SetSet().SetSeq_set().push_back(add);
1992 if(submit->IsSetSub() && !
m_SeqSubmit&& !block_to_add) {
1993 if(!block_to_add) {
1994block_to_add.
Reset(
newobjects::CSubmit_block());
1995block_to_add->Assign(submit->GetSub());
1999 constobjects::CSubmit_block* block =
dynamic_cast<constobjects::CSubmit_block*
>(&ptr);
2001 if(!block_to_add) {
2002block_to_add.
Reset(
newobjects::CSubmit_block());
2003block_to_add->Assign(*block);
2006 constobjects::CSeqdesc* desc =
dynamic_cast<constobjects::CSeqdesc*
>(&ptr);
2009new_desc->Assign(*desc);
2011 cmd->AddCommand(*cmdAddDesc);
2022wxMessageBox(
wxT(
"Unable to read from file"),
wxT(
"Error"),
2023wxOK | wxICON_ERROR,
this);
2025 if(entry_to_add->GetSet().IsSetSeq_set() && entry_to_add->GetSet().GetSeq_set().size() > 0) {
2031wxOK | wxCANCEL | wxICON_ERROR,
this) == wxCANCEL) {
2037 if(dlg.ShowModal() == wxID_OK) {
2079 if(dlg.ShowModal() == wxID_OK)
2094 static const stringsViewType(
"Text View");
2103 if(!
objects.front().object)
2108 if(projectView != 0) {
2109prjSrv->ActivateProjectView(projectView);
2113 type->SetStr(
"TextViewParams");
2121 label->SetStr(
"TextViewType");
2123param->
SetData().SetStr(
"Flat File");
2124 data.push_back(param);
2130 label->SetStr(
"ExpandAll");
2132param->
SetData().SetBool(
true);
2133 data.push_back(param);
2139 label->SetStr(
"TrackSelection");
2141param->
SetData().SetBool(
true);
2142 data.push_back(param);
2145prjSrv->AddProjectView(sViewType,
objects, params);
2156 m_Book->AdvanceSelection(
false);
2166 m_Book->AdvanceSelection(
true);
2186 static const stringsViewType(
"Validate Table View");
2195 if(!
objects->GetData().front().object)
2199 IProjectView* projectView = prjSrv->FindView(*(
objects->GetData().front().object), sViewType);
2200 if(projectView != 0) {
2201prjSrv->ActivateProjectView(projectView);
2210prjSrv->AddProjectView(sViewType,
objects->GetData(), 0);
2222wxMessageDialog dlg(
this,
wxT(
"No information to clear. You may start entering data now."),
wxT(
"Clear Data"), wxOK);
2228wxMessageDialog dlg(
this,
wxT(
"You have not saved the most recent changes to this submission. Are you sure you want to abandon this and start a new submission?"),
wxT(
"Clear Data"), wxOK|wxCANCEL);
2229 intanswer = dlg.ShowModal();
2230 if(answer == wxID_CANCEL) {
2238 th.SetSet().Reset();
2241objects::CSeq_entry_EditHandle eh =
m_TopSeqEntry.GetScope().GetSeq_entryEditHandle(*e);
2270wxMessageDialog dlg(
this,
wxT(
"You have not saved the most recent changes to this submission. Are you sure you want to abandon this and start a new submission?"),
wxT(
"Clear Data"), wxOK|wxCANCEL);
2271 intanswer = dlg.ShowModal();
2272 if(answer == wxID_CANCEL) {
2282 th.SetSet().Reset();
2285objects::CSeq_entry_EditHandle eh =
m_TopSeqEntry.GetScope().GetSeq_entryEditHandle(*e);
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.
User-defined methods of the data storage class.
bool GUI_AsyncExecUnit(IExecuteUnit &exec_unit, const wxString &msg)
bool IsGeneralIdProtPresent(objects::CSeq_entry_Handle tse)
void AddCommand(IEditCommand &command)
virtual void SetRegistryPath(const string &path)
virtual CRef< objects::CSeq_table > GetValuesTableFromSeqEntry(objects::CSeq_entry_Handle seh)
virtual CRef< objects::CSeqTable_column > MakeProblemsColumn(CRef< objects::CSeq_table > values_table)
static wxString GetDialogFilter(EFileType fileType)
static string MakeKey(const string §ion, const string &key, const string &delim=CGuiRegistry::kDecimalDot)
create a key from a section and a subkey
CRegistryWriteView GetWriteView(const string §ion)
get a read-write view at a particular level.
static CGuiRegistry & GetInstance()
access the application-wide singleton
CRegistryReadView GetReadView(const string §ion) const
get a read-only view at a particular level.
CIRef< IEditCommand > ImportFeaturesFromFile(const wxString &workDir=wxEmptyString, const string &format_id=kEmptyStr)
static void ShowTableInfo()
virtual CRef< objects::CSeq_table > GetValuesTableFromSeqEntry(objects::CSeq_entry_Handle seh)
virtual CRef< CCmdComposite > GetCommandFromValuesTable(CRef< objects::CSeq_table >, objects::CSeq_entry_Handle seh)
IObjectLoader * GetObjectLoader()
void SetManagers(vector< CIRef< IOpenObjectsPanelClient > > &managers)
CProjectService - a service providing API for operations with Workspaces and Projects.
class CRegistryReadView provides a nested hierarchical view at a particular key.
CRef< CCmdComposite > GetCommand()
CRef< CCmdComposite > GetCommand()
virtual bool Show(bool show=1)
Report opening events in dialogs used in the editing package.
CRef< objects::CSeq_table > GetReplacementTable()
Base class for all serializable objects.
@ eWizardType_uncultured_samples
@ eWizardType_microsatellite
@ eWizardType_rrna_its_igs
CRef< objects::CSeqTable_column > CheckSourceQuals(CRef< objects::CSeq_table > values_table)
CSourceRequirements::EWizardType GetWizardTypeFromCtrl()
void RefreshSubmitterInfoStatus()
void OnButton17Click(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON17
static bool ShowToolTips()
Should we show tooltips?
string x_CheckSourceQuals(CSourceRequirements::EWizardType wizard_type)
CSubPrepIntroPanel * m_IntroPanel
CSubmissionPrepMainPanel * m_MainPanel
static string GetWizardTypeName(unsigned int wizard_type)
wxBoxSizer * m_StarExplanation
static string GetWizardFieldFromSeqEntry(objects::CSeq_entry_Handle entry, string field_name)
CRef< objects::CSubmit_block > GetSubmitBlock()
wxStaticText * m_SequenceCount
CRef< objects::CSeq_table > x_BuildValuesTable()
void x_CreateGenomeOptions(CSourceRequirements::EWizardType wizard_type, CSourceRequirements::EWizardSrcType src_type)
void OnStartNewClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_START_NEW
CRef< CCmdComposite > x_ClearWizardSpecificData(CSourceRequirements::EWizardType wizard_type)
wxButton * m_ValidateButton
void x_UpdateSequenceCountLabel()
static CSourceRequirements::EWizardType GetWizardTypefromSeqEntry(objects::CSeq_entry_Handle entry)
wxBitmap GetBitmapResource(const wxString &name)
Retrieves bitmap resources.
vector< size_t > x_GetSequenceLengths(CRef< objects::CSeq_table > table)
void OnSaveBtnClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_SAVE_BTN
void ImportFeatureTableFile()
CRef< objects::CSeq_submit > m_SeqSubmit
void SetSubmissionNotReady(string error)
wxIcon GetIconResource(const wxString &name)
Retrieves icon resources.
void OnRemoveSequencesClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON16
bool x_NeedTopology(CSourceRequirements::EWizardType wizard_type, CMolInfoTableCommandConverter *converter)
void OnAddSequenceBtnClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_ADD_SEQUENCE_BTN
CSubPrep_panel()
Constructors.
string GetWizardTypeField()
bool OkToBulkEditSeqTech()
wxButton * m_VectorTrimBtn
bool Create(wxWindow *parent, wxWindowID id=ID_CSUBPREP_PANEL, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
Creation.
virtual void SaveSettings() const
void HandleBulkCmdDlg(CBulkCmdDlg *dlg, string label="")
void CreateControls()
Creates the controls and sizers.
void SetAltEmailAddress(string alt_email)
void x_ConvertToSeqSubmit()
void x_EnableSeqButtons()
objects::CSeqdesc_CI GetCitSubPub()
virtual void LoadSettings()
void x_SetSourceTypeOptionsForWizardType(CSourceRequirements::EWizardType wizard_type)
void OnLookupTaxonomyClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_LOOKUP_TAXONOMY
static CSourceRequirements::EWizardType GuessWizardTypefromSeqEntry(objects::CSeq_entry_Handle entry)
pair< CSourceRequirements::EWizardType, string > TWizardKeyword
void OnNotebookPageChanged(wxNotebookEvent &event)
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED event handler for ID_NOTEBOOK
wxButton * m_RemoveSequencesBtn
void OnPrevBtnClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PREV_BTN
CSourceRequirements::EWizardSrcType x_GetWizardSrcTypeFromCtrls()
void OnFlatfileClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_FLATFILE
void x_RefreshSubmitterInfoStatus()
bool IsSequencingTechnologyRequired(CSourceRequirements::EWizardType wizard_type)
void OnChangeSet(wxCommandEvent &event)
~CSubPrep_panel()
Destructor.
void x_CreateCommentOptions(const string &comment_label)
CTableCommandConverter * GetConverterForFieldName(string field_name)
wxButton * m_FlatfileButton
void x_LaunchVectorTrimEditor()
void OnClickVectorTrim(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON13
void Init()
Initialises member variables.
void UpdateForSeqEntryChange()
void x_CreateDBLinkOptions()
static CRef< CCmdComposite > SetWizardFieldInSeqEntry(objects::CSeq_entry_Handle entry, string field_name, string value)
void x_SetSubmissionStatus()
CSourceRequirements::EWizardType SetWizardType(CSourceRequirements::EWizardType wizard_type)
string GetWizardSrcTypeField()
TConstScopedObjects * m_InputObjects
void LaunchFeatureAdder()
void x_UpdateFeatureStatus(CSourceRequirements::EWizardType wizard_type)
void LaunchSourceEditor()
CFeatureTableCommandConverter * x_GetMicrosatelliteTableConverter()
CRef< objects::CSeq_table > GetSeqTechTable()
void x_CreatePrimerOptions()
void LaunchSeqTechEditor()
TWizardKeywordList m_WizardNames
bool x_IsSequencingTechnologyRequired(objects::CSeq_entry_Handle entry, CSourceRequirements::EWizardType wizard_type)
void ClearSeqTechValues()
vector< bool > m_DBLinkRequired
vector< string > m_DBLinkUrls
void x_CreateChimeraOptions()
void SetSourceType(string src_type)
void OnNextBtnClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_NEXT_BTN
virtual bool TransferDataToWindow()
Transfer data to the window.
wxButton * m_ReorderSequencesBtn
void x_CreateWizardExtras()
wxButton * m_TaxonomyButton
objects::CSeq_entry_Handle m_TopSeqEntry
void x_CreateMoleculeOptions(CSourceRequirements::EWizardType wizard_type, CSourceRequirements::EWizardSrcType src_type)
string m_SubmissionErrors
void OnValidateClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_VALIDATE
ICommandProccessor * m_CmdProcessor
TWizardKeywordList m_Keywords
vector< string > m_DBLinkFields
bool x_NeedUniqueMicrosatelliteNames()
void UpdateSubmitBlock(CRef< objects::CSubmit_block > new_block, CRef< objects::CCit_gen > new_gen, string alt_email)
CSourceRequirements::EWizardType x_GetWizardTypeFromCtrl()
CSourceRequirements::EWizardType GetWizardType()
CSourceRequirements::EWizardSrcType x_GetWizardSrcTypefromSeqEntry(objects::CSeq_entry_Handle entry)
void x_SetSourceType(CSourceRequirements::EWizardSrcType src_type)
void OnReorderSeqClick(wxCommandEvent &event)
wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_REORDER_SEQ
void AddField(objects::CSeq_entry_Handle seh, ICommandProccessor *processor, IWorkbench *workbench, string label, string column_name, CTableFieldCommandConverter *converter, bool must_choose=false, bool required=false, string default_val="", string url="", bool allow_mix=true)
void ShowSourceLabelStar(bool val)
CSourceRequirements::EWizardSrcType GetWizardSrcTypeFromCtrls(CSourceRequirements::EWizardType wizard_type)
void ShowAddFeatureBtn(bool val)
void SetSourceType(CSourceRequirements::EWizardSrcType src_type)
void SetFeaturesLabel(string label)
void SetSourceTypeOptions(CSourceRequirements::EWizardType wizard_type)
CSourceRequirements::EWizardSrcType GetWizardSrcTypeFromName(string name)
void CreateSetChoice(CSourceRequirements::EWizardType wizard_type, objects::CSeq_entry_Handle seh)
void UpdateSeqTechCtrls(CSourceRequirements::EWizardType wizard_type)
void SetSourceLabel(string label)
void CreateVirusMoleculeOptions(objects::CSeq_entry_Handle seh, ICommandProccessor *processor)
void ShowFeaturesStar(bool val)
void ShowChimera(objects::CSeq_entry_Handle seh, ICommandProccessor *processor, IWorkbench *workbench, bool show)
SIZE_TYPE TotalSize() const
CWorkbench - default implementation of IWorkbench.
virtual void Execute(IEditCommand *command, wxWindow *window=0)=0
virtual bool PreExecute()=0
virtual bool PostExecute()=0
vector< SObject > TObjects
class IProjectView defines the abstract interface for views observing projects.
CRef< CCmdComposite > GetCommand()
std::ofstream out("events_result.xml")
main entry point for tests
vector< CRef< CFeatureSeqTableColumnBase > > TFeatureSeqTableColumnList
const char * kMoleculeType
const char * kDefaultMoleculeType
const char * kSequenceIdColLabel
static void cleanup(void)
#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 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.
CIRef< T > GetServiceByType()
retrieves a typed reference to a service, the name of C++ type is used as the name of the service.
virtual wxFrame * GetMainWindow()
returns a pointer to the main application frame window
vector< SConstScopedObject > TConstScopedObjects
virtual bool Send(CEvent *evt, EDispatch disp_how=eDispatch_Default, int pool_name=ePool_Default)
Sends an event synchronously.
#define MSerial_AsnText
I/O stream manipulators â.
static CRef< CObjectManager > GetInstance(void)
Return the existing object manager or create one.
const CSeq_feat_Handle & GetSeq_feat_Handle(void) const
Get original feature handle.
TObjectType * GetPointer(void) const THROWS_NONE
Get pointer,.
TObjectType * GetPointer(void) THROWS_NONE
Get pointer,.
void Reset(void)
Reset reference object.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
IO_PREFIX::ofstream CNcbiOfstream
Portable alias for ofstream.
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.
static bool IsBlank(const CTempString str, SIZE_TYPE pos=0)
Check if a string is blank (has no text).
static void TruncateSpacesInPlace(string &str, ETrunc where=eTrunc_Both)
Truncate whitespace in a string (in-place)
static SIZE_TYPE Find(const CTempString str, const CTempString pattern, ECase use_case=eCase, EDirection direction=eForwardSearch, SIZE_TYPE occurrence=0)
Find the pattern in the string.
static bool EqualNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive equality of a substring with another string.
static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)
Convert numeric value to string.
static bool Equal(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2, ECase use_case=eCase)
Test for equality of a substring with another string.
static string & ReplaceInPlace(string &src, const string &search, const string &replace, SIZE_TYPE start_pos=0, SIZE_TYPE max_replace=0, SIZE_TYPE *num_replace=0)
Replace occurrences of a substring within a string.
static const char label[]
TData & SetData(void)
Assign a value to Data data member.
void SetLabel(TLabel &value)
Assign a value to Label data member.
void SetType(TType &value)
Assign a value to Type data member.
void SetData(TData &value)
Assign a value to Data data member.
vector< CRef< CUser_field > > TData
vector< CStringUTF8 > TString
const TString & GetString(void) const
Get the variant data.
const TData & GetData(void) const
Get the Data member data.
@ eMol_na
just a nucleic acid
<!DOCTYPE HTML >< html > n< header > n< title > PubSeq Gateway Help Page</title > n< style > n th
<!DOCTYPE HTML >< html > n< header > n< title > PubSeq Gateway Help Page</title > n< style > n table
CRef< objects::CSeq_table > BuildDBLinkValuesTableFromSeqEntry(objects::CSeq_entry_Handle seh)
const struct ncbi::grid::netcache::search::fields::SIZE size
const GenericPointer< typename T::ValueType > T2 value
CRef< CSeqTable_column > FindSeqTableColumnByName(CRef< objects::CSeq_table > values_table, string column_name)
void SetColumnValue(CRef< CSeqTable_column > col, string val)
CSourceRequirements * GetSrcRequirements(CSourceRequirements::EWizardType wizard_type, CSourceRequirements::EWizardSrcType source_type, CRef< objects::CSeq_table > values_table)
CRef< objects::CSeq_table > GetSeqTableForSrcQualFromSeqEntry(objects::CSeq_entry_Handle seh, vector< string > qual_names)
CRef< objects::CSeq_table > GetSeqTableFromSeqEntry(objects::CSeq_entry_Handle seh)
#define row(bind, expected)
static CSubPrep_panel::TWizardKeyword s_keywords[]
const string kSubmissionOk
static bool s_MatchesFieldName(string field_name, string label)
const string kChimeraLabel
const string kNotReadyForSubmission
static const string kAssemblyDescription
const string kChimeraField
const string kSubmissionStatus
static const char * kTableTag
const string kReleaseDateConfirmed
vector< string > FindNonUniqueStrings(const vector< string > &values)
bool AreAnyColumnValuesMissing(CRef< objects::CSeqTable_column > col)
bool AreAllColumnValuesTheSame(CRef< objects::CSeqTable_column > col, string default_val="")
bool AddSeqEntryToSeqEntry(const objects::CSeq_entry *entry, objects::CSeq_entry_Handle seh, CRef< CCmdComposite > cmd, bool &has_nuc, bool &has_prot, bool create_general_only)
CSourceRequirements::EWizardType GetWizardTypeFromName(string wizard_name)
CRef< objects::CUser_object > MakeWizardObject()
CRef< objects::CSeq_table > GetIdsFromSeqEntry(const objects::CSeq_entry &entry)
vector< string > SortUniqueStrings(const vector< string > &values)
bool IsWizardObject(const objects::CUser_object &user)
void SetWizardFieldInSeqEntryNoUndo(objects::CSeq_entry_Handle entry, string field_name, string value)
wxString GetAsnSqnExtensions()
string SummarizeIdProblems(CRef< objects::CSeqTable_column > problems)
string GetFieldFromWizardObject(const objects::CUser_object &user, string field_name)
void ApplyReplacementIds(objects::CSeq_entry &entry, CRef< objects::CSeq_table > table)
bool AreAnyColumnValuesPresent(CRef< objects::CSeqTable_column > col, string default_val="")
string CheckFeatureAnnotation(objects::CSeq_entry_Handle entry, bool &is_ok)
CRef< objects::CSeqTable_column > GetSeqIdProblems(CRef< objects::CSeq_table > new_ids, CRef< objects::CSeq_table > old_ids, size_t max_len)
TWizardNameList GetWizardNameList()
#define SYMBOL_CTBLEDITDLG_IDNAME
vector< string > GetAssemblyDataFields()
void GetProductToCDSMap(objects::CScope &scope, map< objects::CBioseq_Handle, set< objects::CSeq_feat_Handle > > &product_to_cds)
CRef< CCmdComposite > TaxonomyLookupCommand(objects::CSeq_entry_Handle seh)
CRef< CCmdComposite > GetDeleteFeatureCommand(const objects::CSeq_feat_Handle &fh, bool remove_proteins=true)
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