switch (tkn.type) { case TT_EORECORD: record.add(tkn.content.toString()); break; case TT_EOF: if (tkn.isReady) { record.add(tkn.content.toString()); } else { ret = null; } break; case TT_INVALID: default:  throw new IOException( "(line " + getLineNumber() + ") invalid parse sequence");  } if (record.size() > 0) { ret = new String[record.size()]; record.toArray(ret);
if (!record.isEmpty()) { ret = (String[]) record.toArray(new String[record.size()]);
  public String[] getLine() throws IOException {    Vector record = new Vector();    String[] ret = new String[0];    Token tkn;    while ((tkn = nextToken()).type == TT_TOKEN) {      record.add(tkn.content.toString());      }    // did we reached eorecord or eof ?    switch (tkn.type) {      case TT_EORECORD:        record.add(tkn.content.toString());        break;      case TT_EOF:        if (tkn.isReady) {          record.add(tkn.content.toString());        } else {          ret = null;        }        break;      case TT_INVALID:      default:        // error: throw IOException        throw new IOException(          "(line " + getLineNumber()           + ") invalid parse sequence");        // unreachable: break;    }    if (record.size() > 0) {      ret = new String[record.size()];      record.toArray(ret);    }    return ret;  }