{\r
SequenceI[] msa = gatherSequencesForAlignment();\r
new jalview.ws.MsaWSClient(sh, title, msa,\r
- false, true);\r
+ false, true, viewport.getAlignment().getDataset());\r
\r
}\r
\r
{\r
SequenceI[] msa = gatherSequencesForAlignment();\r
new jalview.ws.MsaWSClient(sh, title, msa,\r
- true, true);\r
+ true, true, viewport.getAlignment().getDataset());\r
\r
}\r
\r
*/\r
\r
public MsaWSClient(ext.vamsas.ServiceHandle sh, String altitle, SequenceI[] msa,\r
- boolean submitGaps, boolean preserveOrder)\r
+ boolean submitGaps, boolean preserveOrder, Alignment seqdataset)\r
{\r
\r
if (!sh.getAbstractName().equals("MsaWS"))\r
\r
return;\r
}\r
- startMsaWSClient(altitle, msa, submitGaps, preserveOrder);\r
+ startMsaWSClient(altitle, msa, submitGaps, preserveOrder, seqdataset);\r
\r
}\r
\r
\r
private void startMsaWSClient(String altitle, SequenceI[] msa,\r
- boolean submitGaps, boolean preserveOrder)\r
+ boolean submitGaps, boolean preserveOrder, Alignment seqdataset)\r
{\r
if (!locateWebService())\r
{\r
\r
MsaWSThread musclethread = new MsaWSThread(WebServiceName +\r
" alignment of " + altitle, msa,\r
- submitGaps, preserveOrder);\r
+ submitGaps, preserveOrder, seqdataset);\r
wsInfo.setthisService(musclethread);\r
musclethread.start();\r
}\r
vamsas.objects.simple.SequenceSet seqs = new vamsas.objects.simple.\r
SequenceSet();\r
Hashtable SeqNames = null;\r
- boolean submitGaps = false; // and always store and recover sequence order\r
+ boolean submitGaps = false; // pass sequences including gaps to alignment service\r
boolean preserveOrder = true; // and always store and recover sequence order\r
String jobId;\r
String alTitle; // name which will be used to form new alignment window.\r
int allowedServerExceptions = 3; // thread dies if too many exceptions.\r
boolean jobComplete = false;\r
\r
+ Alignment dataset; // dataset to which the new alignment will be associated.\r
+\r
MsaWSThread(String title, SequenceI[] msa, boolean subgaps,\r
- boolean presorder)\r
+ boolean presorder, Alignment seqset)\r
{\r
alTitle = title;\r
submitGaps = subgaps;\r
preserveOrder = presorder;\r
-\r
+ dataset = seqset;\r
OutputHeader = wsInfo.getProgressText();\r
SeqNames = new Hashtable();\r
\r
jalview.analysis.SeqsetUtils.deuniquify(SeqNames, seqs);\r
\r
Alignment al = new Alignment(seqs);\r
-\r
+ if (dataset!=null) {\r
+ al.setDataset(dataset);\r
+ }\r
// TODO: JBPNote Should also rename the query sequence sometime...\r
AlignFrame af = new AlignFrame(al);\r
af.addSortByOrderMenuItem(ServiceName + " Ordering",\r