import java.util.List;
import java.util.Map;
-import com.sun.xml.internal.ws.developer.ServerSideException;
import compbio.data.msa.SequenceAnnotation;
import compbio.data.sequence.FastaSequence;
import compbio.data.sequence.ScoreManager;
} catch (Exception x)
{
- if (x.getCause() instanceof ServerSideException)
+ if (x.getMessage().contains(
+ "Position in a file could not be negative!"))
{
- if (x.getMessage().contains("Position in a file could not be negative!"))
- {
- // squash index out of bounds exception- seems to happen for
- // disorder predictors which don't (apparently) produce any
- // progress information and JABA server throws an exception
- // because progress length is -1.
- stats = null;
- }
- else
- {
- throw x;
- }
+ // squash index out of bounds exception- seems to happen for
+ // disorder predictors which don't (apparently) produce any
+ // progress information and JABA server throws an exception
+ // because progress length is -1.
+ stats = null;
}
else
{
boolean nucleotidesAllowed = false;
boolean proteinAllowed = false;
-
+
/**
* record sequences for mapping result back to afterwards
*/
- protected boolean bySequence=false;
+ protected boolean bySequence = false;
+
+ Map<String, SequenceI> seqNames;
- Map<String,SequenceI> seqNames;
public List<FastaSequence> getInputSequences(AlignmentI alignment)
{
int minlen = 10;
if (bySequence)
{
- seqNames=new HashMap<String,SequenceI>();
+ seqNames = new HashMap<String, SequenceI>();
}
for (SequenceI sq : ((List<SequenceI>) alignment.getSequences()))
{
{
String newname = SeqsetUtils.unique_name(seqs.size() + 1);
// make new input sequence with or without gaps
- if (seqNames!=null) {
- seqNames.put(newname,sq);
+ if (seqNames != null)
+ {
+ seqNames.put(newname, sq);
}
seqs.add(new compbio.data.sequence.FastaSequence(newname,
(submitGaps) ? sq.getSequenceAsString() : AlignSeq