@Test public void testNext() throws IOException{ assertTrue(concatFilter.incrementToken()); TermAttribute termAtt = (TermAttribute)concatFilter.getAttribute(TermAttribute.class); OffsetAttribute offsetAtt = (OffsetAttribute)concatFilter.getAttribute(OffsetAttribute.class); assertEquals(0, offsetAtt.startOffset()); assertEquals(17, offsetAtt.endOffset()); assertEquals("token1|token2|token3", termAtt.term()); }
@Override @Deprecated public Token next(Token reusableToken) throws IOException { String tokenText = concatenatedInputTokenTerms(reusableToken); reusableToken.setTermBuffer(tokenText.toCharArray(), 0, tokenText.length()); reusableToken.setStartOffset(startOffset); reusableToken.setEndOffset(lastToken.endOffset()); return reusableToken; }
ConcatFilter extends TokenFilter { @Override @Deprecated public Token next(Token reusableToken) throws IOException { String tokenText = concatenatedInputTokenTerms(reusableToken); reusableToken.setTermBuffer(tokenText.toCharArray(), 0, tokenText.length()); reusableToken.setStartOffset(startOffset); reusableToken.setEndOffset(lastToken.endOffset()); return reusableToken; } }
ConcatFilter extends TokenFilter { @Override @Deprecated public Token next(Token reusableToken) throws IOException { String tokenText = concatenatedInputTokenTerms(reusableToken); reusableToken.setTermBuffer(tokenText.toCharArray(), 0, tokenText.length()); reusableToken.setStartOffset(startOffset); reusableToken.setEndOffset(lastToken.endOffset()); return reusableToken; } protected  ConcatFilter(TokenStream input, String concatString); }
ConcatFilter extends TokenFilter { @Override @Deprecated public Token next(Token reusableToken) throws IOException { String tokenText = concatenatedInputTokenTerms(reusableToken); reusableToken.setTermBuffer(tokenText.toCharArray(), 0, tokenText.length()); reusableToken.setStartOffset(startOffset); reusableToken.setEndOffset(lastToken.endOffset()); return reusableToken; } protected  ConcatFilter(TokenStream input, String concatString); @Override boolean incrementToken(); @Override @Deprecated Token next(Token reusableToken); }
ConcatFilter extends TokenFilter { @Override @Deprecated public Token next(Token reusableToken) throws IOException { String tokenText = concatenatedInputTokenTerms(reusableToken); reusableToken.setTermBuffer(tokenText.toCharArray(), 0, tokenText.length()); reusableToken.setStartOffset(startOffset); reusableToken.setEndOffset(lastToken.endOffset()); return reusableToken; } protected  ConcatFilter(TokenStream input, String concatString); @Override boolean incrementToken(); @Override @Deprecated Token next(Token reusableToken);  }