Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.knowgate.lucene
Class MailIndexer

    java.lang.Object
      com.knowgate.lucene.Indexer
          com.knowgate.lucene.MailIndexer

    public class MailIndexer

extends Indexer

Indexer subclass for e-mail messages

Field Summary

Fields inherited from class com.knowgate.lucene.Indexer
`DEFAULT_ANALYZER`

Constructor Summary
`MailIndexer()`

Method Summary
`static void` | `addMail(IndexWriter oIWrt, java.lang.String sGuid, java.math.BigDecimal dNumber, java.lang.String sWorkArea, java.lang.String sContainer, java.lang.String sSubject, java.lang.String sAuthor, java.lang.String sRecipients, java.util.Date dtSent, java.lang.String sComments, java.io.InputStream oStrm, int iSize)` Add a single mail message to the index
`static void` | `rebuildFolder(java.util.Properties oProps, java.lang.String sWorkArea, java.lang.String sFolder)` Re-build full text index for a given mail folder All previously indexed messages for given folder are removed from index and written back

Methods inherited from class com.knowgate.lucene.Indexer
`add, add, add, delete, main, optimize, rebuild, rebuild`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MailIndexer

    public MailIndexer()

Method Detail

### addMail

    public static void addMail(IndexWriter oIWrt,
                               java.lang.String sGuid,
                               java.math.BigDecimal dNumber,
                               java.lang.String sWorkArea,
                               java.lang.String sContainer,
                               java.lang.String sSubject,
                               java.lang.String sAuthor,
                               java.lang.String sRecipients,
                               java.util.Date dtSent,
                               java.lang.String sComments,
                               java.io.InputStream oStrm,
                               int iSize)
                        throws java.lang.ClassNotFoundException,
                               java.io.IOException,
                               java.lang.IllegalArgumentException,
                               java.lang.NoSuchFieldException,
                               java.lang.IllegalAccessException,
                               java.lang.InstantiationException,
                               java.lang.NullPointerException

  Add a single mail message to the index

  Parameters:
    `oIWrt` - IndexWriter
    `sGuid` - String GUID of mime message to be indexed (from gu_mimemsg field of table k_mime_msgs)
    `dNumber` - BigDecimal mime message number (from pg_message field of table k_mime_msgs)
    `sWorkArea` - String GUID of WorkArea (from gu_workarea field of table k_mime_msgs)
    `sContainer` - String Name of Category (Folder) where message is stored. This is nm_category field at k_categories table record corresponding to gu_category from k_mime_msgs
    `sSubject` - String Subject
    `sAuthor` - String Display name of message sender
    `sRecipients` - String Recipients list (both display name and e-mails)
    `dtSent` - Date
    `sComments` - String
    `oStrm` - InputStream Full mime message body as an InputStream (from by_content field of table k_mime_msgs)
  Throws:
    `java.lang.ClassNotFoundException`
    `java.io.IOException`
    `java.lang.IllegalArgumentException`
    `java.lang.NoSuchFieldException`
    `java.lang.IllegalAccessException`
    `java.lang.InstantiationException`
    `java.lang.NullPointerException`

### rebuildFolder

    public static void rebuildFolder(java.util.Properties oProps,
                                     java.lang.String sWorkArea,
                                     java.lang.String sFolder)
                              throws java.sql.SQLException,
                                     java.io.IOException,
                                     java.lang.ClassNotFoundException,
                                     java.lang.IllegalArgumentException,
                                     java.lang.NoSuchFieldException,
                                     java.lang.IllegalAccessException,
                                     java.lang.InstantiationException

  Re-build full text index for a given mail folder

  All previously indexed messages for given folder are removed from index and written back

  Parameters:
    `oProps` - Properties containing: luceneindex, driver, dburl, dbuser, dbpassword
    `sWorkArea` - String GUID of WorkArea to which folder belongs
    `sFolder` - String Folder name as in field nm_category of table k_categories
  Throws:
    `java.sql.SQLException`
    `java.io.IOException`
    `java.lang.ClassNotFoundException`
    `java.lang.IllegalArgumentException`
    `java.lang.NoSuchFieldException`
    `java.lang.IllegalAccessException`
    `java.lang.InstantiationException`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD