git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17c8e30
)
fix for pfam files with empty annotation or sequence entries
author
jprocter
<Jim Procter>
Tue, 13 Oct 2009 15:24:07 +0000
(15:24 +0000)
committer
jprocter
<Jim Procter>
Tue, 13 Oct 2009 15:24:07 +0000
(15:24 +0000)
src/jalview/io/PfamFile.java
patch
|
blob
|
history
diff --git
a/src/jalview/io/PfamFile.java
b/src/jalview/io/PfamFile.java
index
7e0a976
..
5e9df60
100755
(executable)
--- a/
src/jalview/io/PfamFile.java
+++ b/
src/jalview/io/PfamFile.java
@@
-60,6
+60,7
@@
public class PfamFile extends AlignFile
{
if (line.indexOf("#") != 0)
{
+ // TODO: verify pfam format requires spaces and not tab characters - if not upgrade to use stevesoft regex and look for whitespace.
StringTokenizer str = new StringTokenizer(line, " ");
String id = "";
@@
-83,8
+84,10
@@
public class PfamFile extends AlignFile
{
headers.addElement(id);
}
-
- tempseq.append(str.nextToken());
+ if (str.hasMoreTokens())
+ {
+ tempseq.append(str.nextToken());
+ }
}
}
}