return getTermsFor(new StringReader(s));
}
private String[] getTermsFor(Reader r) {
List<String> l = new LinkedList<String>();
JFlexTokenizer ts = (JFlexTokenizer) this.analyzer.createComponents("refs", r).getTokenStream();
ts.yyreset(r);
CharTermAttribute term = ts.addAttribute(CharTermAttribute.class);
try {
while (ts.yylex()) {
l.add(term.toString());
}
} catch (IOException ex) {
throw new RuntimeException(ex);
}