Class Search.Hit

  • Enclosing class:
    Search

    public final class Search.Hit
    extends java.lang.Object
    A hit within the search result.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getExcerpt()  
      java.lang.String getExtension()
      Returns the extension of the url of this hit.
      java.lang.String getIcon()
      Returns an icon image for this hit.
      java.util.Map getProperties()  
      java.lang.String getSimilarURL()  
      java.lang.String getTitle()
      Returns the title for this hit.
      java.lang.String getURL()  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getTitle

        public java.lang.String getTitle()
                                  throws RepositoryException
        Returns the title for this hit. The returned string may contain HTML tags, which means it must not be escaped when written to the response.
        Returns:
        the title for this hit.
        Throws:
        RepositoryException - if an error occurs while reading form the repository.
      • getExcerpt

        public java.lang.String getExcerpt()
                                    throws RepositoryException
        Returns:
        the default excerpt for this hit.
        Throws:
        RepositoryException - if an error occurs while building the excerpt.
      • getSimilarURL

        public java.lang.String getSimilarURL()
                                       throws RepositoryException
        Returns:
        the url that displays similar pages for this hit.
        Throws:
        RepositoryException - if an error occurs while reading from the query result.
      • getIcon

        public java.lang.String getIcon()
                                 throws RepositoryException
        Returns an icon image for this hit.
        Returns:
        an icon image for this hit.
        Throws:
        RepositoryException - if an error occurs while reading from the repository.
      • getExtension

        public java.lang.String getExtension()
                                      throws RepositoryException
        Returns the extension of the url of this hit.
        Returns:
        the extension
        Throws:
        RepositoryException - if an error occurs
      • getProperties

        public java.util.Map getProperties()
                                    throws RepositoryException
        Returns:
        the content properties on this hit.
        Throws:
        RepositoryException - if an error occurs while reading from the repository.