Example usage for org.apache.lucene.analysis.ja.tokenattributes InflectionAttribute getInflectionType

List of usage examples for org.apache.lucene.analysis.ja.tokenattributes InflectionAttribute getInflectionType

Introduction

In this page you can find the example usage for org.apache.lucene.analysis.ja.tokenattributes InflectionAttribute getInflectionType.

Prototype

public String getInflectionType();

Source Link

Usage

From source file:com.github.riccardove.easyjasub.lucene.LuceneParser.java

License:Apache License

private void readInflection(TokenStream tokenStream, LuceneToken token) {
    InflectionAttribute inflection = tokenStream.getAttribute(InflectionAttribute.class);
    if (inflection != null) {
        token.setInflectionForm(LuceneUtil.translateInflectedForm(inflection.getInflectionForm()));
        token.setInflectionType(LuceneUtil.translateInflectionType(inflection.getInflectionType()));
    }/*from  ww w.jav a 2  s.c  o  m*/
}