Class UnknownDictionaryWriter

java.lang.Object
org.apache.lucene.analysis.ja.util.BinaryDictionaryWriter
org.apache.lucene.analysis.ja.util.UnknownDictionaryWriter

class UnknownDictionaryWriter extends BinaryDictionaryWriter
  • Field Details

  • Constructor Details

    • UnknownDictionaryWriter

      public UnknownDictionaryWriter(int size)
  • Method Details

    • put

      public int put(String[] entry)
      Description copied from class: BinaryDictionaryWriter
      put the entry in map
      Overrides:
      put in class BinaryDictionaryWriter
      Returns:
      current position of buffer, which will be wordId of next entry
    • putCharacterCategory

      public void putCharacterCategory(int codePoint, String characterClassName)
      Put mapping from unicode code point to character class.
      Parameters:
      codePoint - code point
      characterClassName - character class name
    • putInvokeDefinition

      public void putInvokeDefinition(String characterClassName, int invoke, int group, int length)
    • write

      public void write(Path baseDir) throws IOException
      Description copied from class: BinaryDictionaryWriter
      Write dictionary in file Dictionary format is: [Size of dictionary(int)], [entry:{left id(short)}{right id(short)}{word cost(short)}{length of pos info(short)}{pos info(char)}], [entry...], [entry...].....
      Overrides:
      write in class BinaryDictionaryWriter
      Throws:
      IOException - if an I/O error occurs writing the dictionary files