Class SearchTemplates.InitialTermParser

  • All Implemented Interfaces:
    SearchTemplates.TermParser
    Enclosing class:
    SearchTemplates

    public static class SearchTemplates.InitialTermParser
    extends Object
    implements SearchTemplates.TermParser
    Adds the first letter of each term as a filter parameter using the name 'initialX' where X is the index of the term. For the argument: {'fname', 'lname' }, produces:
         {
           'initial1' => 'f',
           'initial2' => 'l',
         }
     
    • Constructor Detail

      • InitialTermParser

        public InitialTermParser()
    • Method Detail

      • getInitials

        private String[] getInitials​(String[] names)
        This converts an array of names into an array of initials.
        Parameters:
        names - to convert to initials
        Returns:
        initials