GitHub user PaulElschot opened a pull request:

    https://github.com/apache/lucene-solr/pull/53

    Add PrefillTokenStream in analysis common module

    This class is taken from the proposed label module, the tests there also 
pass when using this.
    
    It is a token stream that can be prefilled by adding token states, much 
like CachingTokenFilter and TeeSinkTokenFilter.SinkTokenStream, but the 
addState method here is public.
    It is used in the label module to build token streams.
    
    Some questions:
    
    Is this a good way to build multiple streams from a single input stream?
    When not, I'll need to use another way to build token streams in the label 
module.
    
    This duplicates some code in CachingTokenFilter and 
TeeSinkTokenFilter.SinkTokenStream.
    Should this rather be a superclass of TeeSinkTokenFilter.SinkTokenStream? 
In that case an extra non final class would also be needed to allow the 
inheritance, because an instantiated TokenStream subclass must be final.


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/PaulElschot/lucene-solr pfts-201405a

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/lucene-solr/pull/53.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #53
    
----
commit f8a6af5f1b0f07e6e8afdcd6e120a41c932a2600
Author: Paul Elschot <paul.j.elsc...@gmail.com>
Date:   2014-05-18T21:53:21Z

    Add PrefillTokenStream in analysis common module

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to