diff options
Diffstat (limited to 'java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java | 25 |
1 files changed, 1 insertions, 24 deletions
diff --git a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java index 8e1e14e9e..9f8842c9f 100644 --- a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java +++ b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java @@ -375,7 +375,7 @@ public final class BinaryDictIOUtils { * @param info the char group info to be written. * @return the size written, in bytes. */ - public static int writeCharGroup(final OutputStream destination, final CharGroupInfo info) + private static int writeCharGroup(final OutputStream destination, final CharGroupInfo info) throws IOException { int size = FormatSpec.GROUP_FLAGS_SIZE; destination.write((byte)info.mFlags); @@ -507,29 +507,6 @@ public final class BinaryDictIOUtils { return size + FormatSpec.FORWARD_LINK_ADDRESS_SIZE; } - /** - * Find a word using the Ver3DictDecoder. - * - * @param dictDecoder the dict reader - * @param word the word searched - * @return the found group - * @throws IOException - * @throws UnsupportedFormatException - */ - @UsedForTesting - public static CharGroupInfo findWordByBinaryDictReader(final Ver3DictDecoder dictDecoder, - final String word) throws IOException, UnsupportedFormatException { - int position = getTerminalPosition(dictDecoder, word); - final DictBuffer dictBuffer = dictDecoder.getDictBuffer(); - if (position != FormatSpec.NOT_VALID_WORD) { - dictBuffer.position(0); - final FileHeader header = dictDecoder.readHeader(); - dictBuffer.position(position); - return dictDecoder.readPtNode(position, header.mFormatOptions); - } - return null; - } - private static final int HEADER_READING_BUFFER_SIZE = 16384; /** * Convenience method to read the header of a binary file. |