java.lang.Object
com.atlassian.confluence.impl.search.v2.extractor.TitleExtractor
All Implemented Interfaces:
Extractor2

public class TitleExtractor extends Object implements Extractor2
Responsible for extracting titles for various entities.

All titles are stored to allow display of search results without having to hit database for the title.

Since:
7.20
  • Constructor Details

    • TitleExtractor

      public TitleExtractor()
  • Method Details

    • extractText

      public StringBuilder extractText(Object searchable)
      This method is not relevant to the title extraction and is essentially a no-op.

      Specified by:
      extractText in interface Extractor2
      Parameters:
      searchable - a searchable object
      Returns:
      Returns an empty buffer.
    • extractFields

      public Collection<FieldDescriptor> extractFields(Object searchable)
      Extract fields from the searchable object which implements one of the following interfaces: If an argument implements both interfaces, then the title is extracted in the above listed order.

      Specified by:
      extractFields in interface Extractor2
      Parameters:
      searchable - a searchable object
      Returns:
      list of fields extracted from the searchable object