+ if (!checkPIR) {
+ break;
+ }
+ }
+ }
+ // final check for PIR content. require
+ // >P1;title\n<blah>\nterminated sequence to occur at least once.
+
+ // TODO the PIR/fasta ambiguity may be the use case that is needed to have
+ // a 'Parse as type XXX' parameter for the applet/application.
+ if (checkPIR)
+ {
+ String dta=null;
+ if (!starterm)
+ {
+ do {
+ try {
+ dta = source.nextLine();
+ } catch(IOException ex) {};
+ if (dta!=null && dta.indexOf("*")>-1)
+ {
+ starterm = true;
+ }
+ } while (dta!=null && !starterm);
+ }
+ if (starterm)
+ {
+ reply="PIR";