am cc958dd9
: Refactor BinaryDictInputOutput.
* commit 'cc958dd96eef65fddbc48185c2e88ab18504a377': Refactor BinaryDictInputOutput.
This commit is contained in:
commit
a0fe76f6d5
2 changed files with 2 additions and 7 deletions
|
@ -1596,12 +1596,6 @@ public class BinaryDictInputOutput {
|
|||
return newDict;
|
||||
}
|
||||
|
||||
// TODO: remove this method.
|
||||
public static FusionDictionary readDictionaryBinary(final ByteBuffer buffer,
|
||||
final FusionDictionary dict) throws IOException, UnsupportedFormatException {
|
||||
return readDictionaryBinary(new ByteBufferWrapper(buffer), dict);
|
||||
}
|
||||
|
||||
/**
|
||||
* Basic test to find out whether the file is a binary dictionary or not.
|
||||
*
|
||||
|
|
|
@ -244,7 +244,8 @@ public class DictionaryMaker {
|
|||
inStream = new FileInputStream(file);
|
||||
final ByteBuffer buffer = inStream.getChannel().map(
|
||||
FileChannel.MapMode.READ_ONLY, 0, file.length());
|
||||
return BinaryDictInputOutput.readDictionaryBinary(buffer, null);
|
||||
return BinaryDictInputOutput.readDictionaryBinary(
|
||||
new BinaryDictInputOutput.ByteBufferWrapper(buffer), null);
|
||||
} finally {
|
||||
if (inStream != null) {
|
||||
try {
|
||||
|
|
Loading…
Reference in a new issue