import jalview.io.packed.DataProvider.JvDataType;
import java.io.BufferedReader;
+import java.io.IOException;
import java.util.ArrayList;
import java.util.Hashtable;
import java.util.List;
{
br = new BufferedReader(src.getReader());
}
- context.updateSetModified(new jalview.io.AnnotationFile()
- .parseAnnotationFrom(context.getLastAlignment(), br));
+ if (new jalview.io.AnnotationFile()
+ .parseAnnotationFrom(context.getLastAlignment(), br))
+ {
+ context.updateSetModified(true);
+ } else {
+ errmsg = "Annotation file contained no data.";
+ }
} catch (Exception e)
{
}
}
-
+ if (exerror!=null)
+ {
+ if (errmsg!=null && errmsg.length()>0)
+ {
+ throw new IOException(errmsg,exerror);
+ } else {
+ throw new IOException(errmsg,exerror);
+ }
+ } else {
+ if (errmsg!=null && errmsg.length()>0)
+ {
+ throw new IOException(errmsg);
+ }
+ }
}
if (deuniquify)
{