- if (st.countTokens() == 2)\r
- {\r
- start = Integer.valueOf(st.nextToken()).intValue();\r
- end = Integer.valueOf(st.nextToken()).intValue();\r
- }\r
- else\r
- {\r
- start = -1;\r
- end = -1;\r
- }\r
- }\r
- else\r
- {\r
- ids.addElement(headers.elementAt(i));\r
- }\r
- }\r
- else\r
- {\r
- ids.addElement(headers.elementAt(i));\r
- }\r
-\r
- Sequence newSeq = null;\r
-\r
- if ( (start != -1) && (end != -1))\r
- {\r
- newSeq = new Sequence(ids.elementAt(i).toString(),\r
- seqhash.get(headers.elementAt(i).toString())\r
- .toString(), start, end);\r
- seqs.addElement(newSeq);\r
- }\r
- else\r
- {\r
- newSeq = new Sequence(ids.elementAt(i).toString(),\r
- seqhash.get(headers.elementAt(i).toString())\r
- .toString(), 1,\r
- seqhash.get(headers.elementAt(i).toString())\r
- .toString().length());\r
- seqs.addElement(newSeq);\r
- }\r
+ Sequence newSeq = parseId(headers.elementAt(i).toString());\r
+ newSeq.setSequence( seqhash.get(headers.elementAt(i).toString()).toString());\r
+ seqs.addElement(newSeq);\r