Class LanguagePrefixedTextAnalyzer

  • All Implemented Interfaces:
    Closeable, AutoCloseable

    public class LanguagePrefixedTextAnalyzer
    extends org.apache.lucene.analysis.Analyzer
    A custom Analyzer type, aware about the Solr IndexSchema, which delegates the processing to a custom TokenStream. Although the core part of the logic needed for that dynamic assignment is in LanguagePrefixedTokenStream the actors group is also composed by: Both of them have no specific logic: they exist only because the components involved in the analysis chain don't have access to the IndexSchema instance (e.g. a Tokenizer is a schema concept, while IndexSchema belongs to Solr classes).
    Author:
    Andrea Gazzarini
    See Also:
    LanguagePrefixedTokenStream, LanguagePrefixedTextField
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.apache.lucene.analysis.Analyzer

        org.apache.lucene.analysis.Analyzer.ReuseStrategy, org.apache.lucene.analysis.Analyzer.TokenStreamComponents
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected org.apache.solr.schema.IndexSchema indexSchema  
      AlfrescoAnalyzerWrapper.Mode mode  
      • Fields inherited from class org.apache.lucene.analysis.Analyzer

        GLOBAL_REUSE_STRATEGY, PER_FIELD_REUSE_STRATEGY
    • Constructor Detail

      • LanguagePrefixedTextAnalyzer

        public LanguagePrefixedTextAnalyzer​(org.apache.solr.schema.IndexSchema indexSchema,
                                            AlfrescoAnalyzerWrapper.Mode mode)
    • Method Detail

      • createComponents

        public org.apache.lucene.analysis.Analyzer.TokenStreamComponents createComponents​(String fieldName)
        Specified by:
        createComponents in class org.apache.lucene.analysis.Analyzer