Class DelegatedSearchResultRenderer

  • public class DelegatedSearchResultRenderer
    extends Object
    The class includes the logic to loop through the available search result renderers and pick on that can render the result and use it to render.
    • Constructor Detail

      • DelegatedSearchResultRenderer

        public DelegatedSearchResultRenderer()
    • Method Detail

      • render

        public String render​(SearchResult searchResult,
                             SearchResultRenderContext renderContext)
        Render the given search result. This method will return a rendered search result. If not plugin is found that can render the given search result it will fall back on a default renderer.
        searchResult - The search result to render.
        renderContext - A render context that can hold more information related to the search result. Things like queryString is stored in the context.
        a string of rendered html.
      • setDefaultRenderer

        public void setDefaultRenderer​(SearchResultRenderer defaultRenderer)
        defaultRenderer - the defaultRenderer to set
      • setSearchResultRendererCache

        public void setSearchResultRendererCache​(SearchResultRendererCache cache)
        cache - the cache to set