+ Vector suggestedIds = new Vector();\r
+ /**\r
+ * Creates a new WSWUBlastClient object.\r
+ *\r
+ * @param al DOCUMENT ME!\r
+ * @param ids DOCUMENT ME!\r
+ */\r
+ public WSWUBlastClient(AlignmentPanel ap, AlignmentI al, ArrayList ids)\r
+ {\r
+ this.ap = ap;\r
+ this.al = al;\r
+ output.setText(\r
+ "To display sequence features an exact Uniprot id with 100% sequence identity match must be entered."\r
+ + "\nIn order to display these features, try changing the names of your sequences to the ids suggested below."\r
+ + "\n\nRunning WSWUBlast at EBI."\r
+ + "\nPlease quote Pillai S., Silventoinen V., Kallio K., Senger M., Sobhany S., Tate J., Velankar S., Golovin A., Henrick K., Rice P., Stoehr P., Lopez R."\r
+ +\r
+ "\nSOAP-based services provided by the European Bioinformatics Institute."\r
+ + "\nNucleic Acids Res. 33(1):W25-W28 (2005));");\r
+\r
+ Desktop.addInternalFrame(output,\r
+ "BLASTing for unidentified sequences ", 800, 300);\r
+\r
+ for (int i = 0; i < ids.size(); i++)\r
+ {\r
+ Sequence sequence = (Sequence) ids.get(i);\r
+ System.out.println(sequence.getName());\r
+\r
+ BlastThread thread = new BlastThread(sequence);\r
+ thread.start();\r
+ jobsRunning++;\r
+ }\r
+\r
+ ImageTwirler thread = new ImageTwirler();\r
+ thread.start();\r
+ }\r
+\r
+ /**\r
+ * DOCUMENT ME!\r
+ *\r
+ * @param id1 DOCUMENT ME!\r
+ * @param res DOCUMENT ME!\r
+ */\r
+ void parseResult(Sequence seq, String res)\r
+ {\r
+ StringTokenizer st = new StringTokenizer(res, "\n");\r
+ String data;\r
+ String id2;\r
+ int maxFound = 90;\r
+ StringBuffer buffer = new StringBuffer("\n\n" + seq.getName() + " :");\r
+\r
+ while (st.hasMoreTokens())\r
+ {\r
+ data = st.nextToken();\r
+\r
+ if (data.indexOf(">UNIPROT") > -1)\r
+ {\r
+ int index = data.indexOf(">UNIPROT") + 9;\r
+ id2 = data.substring(index, data.indexOf(" ", index));\r
+\r
+ boolean identitiesFound = false;\r
+ while (!identitiesFound)\r
+ {\r
+ data = st.nextToken();\r
+\r
+ if (data.indexOf("Identities") > -1)\r
+ {\r
+ identitiesFound = true;\r
+\r
+ int value = Integer.parseInt(data.substring(data.indexOf(\r
+ "(") + 1,\r
+ data.indexOf("%")));\r
+\r
+ if (value >= maxFound)\r
+ {\r
+ maxFound = value;\r
+ buffer.append(" " + id2 + " " + value + "%; ");\r
+ suggestedIds.addElement(new Object[]\r
+ {seq, id2});\r
+ }\r
+ }\r
+ }\r
+ }\r
+ }\r
+\r
+ output.appendText(buffer.toString());\r
+ }\r
+\r
+ void updateIds()\r