Class HelpdeskIndexer

java.lang.Object
fr.paris.lutece.plugins.helpdesk.service.search.HelpdeskIndexer
All Implemented Interfaces:
fr.paris.lutece.portal.service.search.SearchIndexer

public class HelpdeskIndexer extends Object implements fr.paris.lutece.portal.service.search.SearchIndexer
Helpdesk Indexer
  • Field Details

  • Constructor Details

    • HelpdeskIndexer

      public HelpdeskIndexer()
  • Method Details

    • getDescription

      public String getDescription()
      Returns the indexer service description
      Specified by:
      getDescription in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Returns:
      The indexer service description
    • indexDocuments

      public void indexDocuments() throws IOException, InterruptedException, fr.paris.lutece.portal.service.message.SiteMessageException
      Index all documents
      Specified by:
      indexDocuments in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Throws:
      IOException - the exception
      InterruptedException - the exception
      fr.paris.lutece.portal.service.message.SiteMessageException - the exception
    • indexSubject

      public void indexSubject(Faq faq, Subject subject) throws IOException, InterruptedException
      Recursive method for indexing a subject and his children
      Parameters:
      faq - the faq linked to the subject
      subject - the subject
      Throws:
      IOException - I/O Exception
      InterruptedException - interruptedException
    • getDocuments

      public List<org.apache.lucene.document.Document> getDocuments(String strDocument) throws IOException, InterruptedException, fr.paris.lutece.portal.service.message.SiteMessageException
      Get the subject document
      Specified by:
      getDocuments in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Parameters:
      strDocument - id of the subject to index
      Returns:
      The list of lucene documents
      Throws:
      IOException - the exception
      InterruptedException - the exception
      fr.paris.lutece.portal.service.message.SiteMessageException - the exception
    • getDocument

      public static org.apache.lucene.document.Document getDocument(int nIdFaq, QuestionAnswer questionAnswer, String strUrl, String strRoleKey, fr.paris.lutece.portal.service.plugin.Plugin plugin) throws IOException, InterruptedException
      Builds a document which will be used by Lucene during the indexing of the question/answer list
      Parameters:
      nIdFaq - The Faq Id
      questionAnswer - the QuestionAnswer to index
      strUrl - the url of the subject
      strRoleKey - The role key
      plugin - The Plugin
      Returns:
      A Lucene Document containing QuestionAnswer Data
      Throws:
      IOException - The IO Exception
      InterruptedException - The InterruptedException
    • getDocument

      public static org.apache.lucene.document.Document getDocument(Subject subject, String strRoleKey, String strUrl, fr.paris.lutece.portal.service.plugin.Plugin plugin) throws IOException, InterruptedException
      Builds a document which will be used by Lucene during the indexing of the subject list
      Parameters:
      subject - the Subject to index
      strUrl - the url of the subject
      strRoleKey - The role key
      plugin - The Plugin
      Returns:
      The Lucene Document containing Subject data
      Throws:
      IOException - The IO Exception
      InterruptedException - The InterruptedException
    • getName

      public String getName()
      Get the name of the indexer.
      Specified by:
      getName in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Returns:
      The name
    • getVersion

      public String getVersion()
      Get the version of the indexer
      Specified by:
      getVersion in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Returns:
      The version number
    • isEnable

      public boolean isEnable()
      Get the state of indexer
      Specified by:
      isEnable in interface fr.paris.lutece.portal.service.search.SearchIndexer
      Returns:
      Return true if the indexer is enabled, false else.
    • getListType

      public List<String> getListType()
      Specified by:
      getListType in interface fr.paris.lutece.portal.service.search.SearchIndexer
    • getSpecificSearchAppUrl

      public String getSpecificSearchAppUrl()
      Specified by:
      getSpecificSearchAppUrl in interface fr.paris.lutece.portal.service.search.SearchIndexer