Документ взят из кэша поисковой машины. Адрес оригинального документа : http://kodomo.fbb.msu.ru/hg/allpy/raw-rev/0ea281d09324
Дата изменения: Unknown
Дата индексирования: Sun Feb 3 01:58:56 2013
Кодировка: UTF-8

# HG changeset patch
# User Boris Nagaev
# Date 1354108570 -14400
# Node ID 0ea281d09324c9e00f75abfdaa3f7f38b40c673d
# Parent f61814d8bef58d9c35e5b6df50be49faab54856d
pair-cores/web: implement compare-aln-3d.cpp application

diff -r f61814d8bef5 -r 0ea281d09324 pair_cores/web/approot/locales/pair-cores-web.xml
--- a/pair_cores/web/approot/locales/pair-cores-web.xml Wed Nov 28 17:15:45 2012 +0400
+++ b/pair_cores/web/approot/locales/pair-cores-web.xml Wed Nov 28 17:16:10 2012 +0400
@@ -41,6 +41,27 @@
PDYLLKGD


+
+

+>1PER_L
+SISSRVKSKRIQLGLNQAELAQKVGTTQQSIEQLENGKTK-RPRFLPELASALGVS
+>1PER_R
+SISSRVKSKRIQLGLNQAELAQKVGTTQQSIEQLENGKTK-RPRFLPELASALGVS
+>1ADR_A_1
+LMGERIRARRKKLKIRQAALGKMVGVSNVAISQWERSETEPNGENLLALSKALQCS
+>1ADR_A_2
+LMGERIRARRKKLKIRQAALGKMVGVSNVAISQWERSETEPNGENLLALSKALQCS
+
+>1PER_L
+SISSRVKSKRIQLGLNQAELAQKVGTTQQSIEQLENGKTKRPRFLPELASALGVS-
+>1PER_R
+SISSRVKSKRIQLGLNQAELAQKVGTTQQSIEQLENGKTKRPRFLPELASALGVS-
+>1ADR_A_1
+LMGERIRARRKKLKIRQAALGKMVGVSNVAISQWERSETEPNGENLLALSKALQCS
+>1ADR_A_2
+LMGERIRARRKKLKIRQAALGKMVGVSNVAISQWERSETEPNGENLLALSKALQCS
+

+


The work was partly supported by
the Russian Foundation for Basic Research, grant 09-04-92743.
@@ -57,6 +78,7 @@
Pair cores file
Pair cores HTML file
Pair cores PyMol file
+ Result



diff -r f61814d8bef5 -r 0ea281d09324 pair_cores/web/approot/locales/pair-cores-web_ru.xml
--- a/pair_cores/web/approot/locales/pair-cores-web_ru.xml Wed Nov 28 17:15:45 2012 +0400
+++ b/pair_cores/web/approot/locales/pair-cores-web_ru.xml Wed Nov 28 17:16:10 2012 +0400
@@ -47,6 +47,7 @@
Парные блоки (текст)
Парные блоки (HTML)
Парные блоки (PyMol-скрипт)
+ Результат



diff -r f61814d8bef5 -r 0ea281d09324 pair_cores/web/compare-aln-3d.cpp
--- a/pair_cores/web/compare-aln-3d.cpp Wed Nov 28 17:15:45 2012 +0400
+++ b/pair_cores/web/compare-aln-3d.cpp Wed Nov 28 17:16:10 2012 +0400
@@ -25,7 +25,7 @@
std::string file = input->file_upload()->clientFileName().toUTF8();
std::string without_extension = file.substr(0, file.find_last_of("."));
if (without_extension.empty()) {
- without_extension = "pair-cores";
+ without_extension = "compare-aln-3d";
}
return without_extension + "." + extension;
}
@@ -68,10 +68,15 @@
//
TableTask* task = new TableTask(root());
//
- TextFileInput* input_aln = new TextFileInput("-i");
- input_aln->text_area()->setColumns(60);
- input_aln->text_area()->setRows(12);
- task->add_input(input_aln, tr("pair.in.Alignment"));
+ TextFileInput* a = new TextFileInput("-a");
+ a->text_area()->setColumns(60);
+ a->text_area()->setRows(12);
+ task->add_input(a, tr("pair.in.Alignment") + " A");
+ //
+ TextFileInput* b = new TextFileInput("-b");
+ b->text_area()->setColumns(60);
+ b->text_area()->setRows(12);
+ task->add_input(b, tr("pair.in.Alignment") + " B");
//
WLineEdit* delta_edit = new WLineEdit("2.0");
delta_edit->setValidator(new WDoubleValidator(0, 10));
@@ -79,85 +84,27 @@
LineEditInput* delta = new LineEditInput(delta_edit, "-d");
task->add_input(delta, tr("pair.in.Delta"));
//
- WLineEdit* width_edit = new WLineEdit("3");
- width_edit->setValidator(new WIntValidator(3, 9999));
- width_edit->validator()->setMandatory(true);
- LineEditInput* width = new LineEditInput(width_edit, "-w");
- task->add_input(width, tr("pair.in.Width"));
- //
- BoolInput* blocks3d = new BoolInput(new WCheckBox(), "--blocks3d");
- task->add_input(blocks3d, tr("pair.in.Blocks3D"));
- //
- BoolInput* ioss = new BoolInput(new WCheckBox(), "-e");
- ioss->set_value_if_true("True");
- task->add_input(ioss, tr("pair.in.SS"));
- //
- WLineEdit* pair_timeout_edit = new WLineEdit("10");
- pair_timeout_edit->setValidator(new WIntValidator(-1, 30 * 24 * 3600));
- pair_timeout_edit->validator()->setMandatory(true);
- LineEditInput* pair_timeout = new LineEditInput(pair_timeout_edit,
- "--pair-timeout");
- task->add_input(pair_timeout, tr("pair.in.Pair_timeout"));
- //
- WLineEdit* blocks3d_timeout_edit = new WLineEdit("-1");
- blocks3d_timeout_edit->setValidator(new WIntValidator(-1, 30 * 24 * 3600));
- blocks3d_timeout_edit->validator()->setMandatory(true);
- LineEditInput* blocks3d_timeout = new LineEditInput(blocks3d_timeout_edit,
- "--blocks3d-timeout");
- task->add_input(blocks3d_timeout, tr("pair.in.Blocks3D_timeout"));
- //
// outputs
//
boost::function name_gen2 = boost::bind(name_gen,
- input_aln, _1);
+ a, _1);
//
- ViewFileOutput* homology = new ViewFileOutput("-y");
- homology->set_suggested_gen(boost::bind(name_gen2, "hom"));
- homology->set_selectable(false);
- task->add_output(homology, tr("pair.out.Homology"));
- //
- ViewFileOutput* pair_blocks = new ViewFileOutput("-b");
- pair_blocks->set_suggested_gen(boost::bind(name_gen2, "blocks"));
- task->add_output(pair_blocks, tr("pair.out.Pair_blocks"));
- //
- ViewFileOutput* pair_html = new ViewFileOutput("-H",
- &FileOutput::unique_name,
- "application/octet-stream",
- "text/html");
- pair_html->set_suggested_gen(boost::bind(name_gen2, "html"));
- task->add_output(pair_html, tr("pair.out.Pair_html"));
- //
- ViewFileOutput* pymol = new ViewFileOutput("-p");
- pymol->set_suggested_gen(boost::bind(name_gen2, "pml"));
- task->add_output(pymol, tr("pair.out.Pymol"));
- //
- ViewFileOutput* high_pymol = new ViewFileOutput("--high-blocks-pymol");
- high_pymol->set_suggested_gen(boost::bind(name_gen2, "pml"));
- task->add_output(high_pymol, tr("pair.out.High_pymol"));
- //
- ViewFileOutput* high_blocks = new ViewFileOutput("--high-blocks");
- high_blocks->set_suggested_gen(boost::bind(name_gen2, "blocks"));
- task->add_output(high_blocks, tr("pair.out.High_blocks"));
- //
- ViewFileOutput* high_html = new ViewFileOutput("--high-blocks-html",
- &FileOutput::unique_name,
- "application/octet-stream",
- "text/html");
- high_html->set_suggested_gen(boost::bind(name_gen2, "html"));
- task->add_output(high_html, tr("pair.out.High_html"));
- //
- PrintFileOutput* execution_log = new PrintFileOutput("&>");
+ ViewFileOutput* execution_log = new ViewFileOutput("2>");
execution_log->set_suggested_gen(boost::bind(name_gen2, "log"));
- execution_log->set_selectable(false);
task->add_output(execution_log, tr("pair.out.Log"));
//
- task->set_runner(new ForkingRunner("pair-cores --no-read-local"));
+ PrintFileOutput* result = new PrintFileOutput("| sed \"s@^@
@\" >");
+ result->set_suggested_gen(boost::bind(name_gen2, "out"));
+ result->set_selectable(false);
+ task->add_output(result, tr("pair.out.Result"));
+ //
+ task->set_runner(new ForkingRunner("compare-aln-3d"));
task->set_queue(&queue);
new TaskCountup(task, root());
//
new WBreak(root());
new Wt::WTemplate(tr("pair.main.Example"), root());
- new Wt::WTemplate(tr("pair.main.Example_fasta"), root());
+ new Wt::WTemplate(tr("pair.main.Example_fasta_compare"), root());
new Wt::WTemplate(tr("pair.main.Rfbr"), root());
}