add capacity to FusionDictionaryBufferInterface.

bug: 6669677

Change-Id: I4627093811a19c46ce13fe351d1db63cbd78cf4a
main
Yuichiro Hanada 2012-09-25 17:52:31 +09:00
parent 35ffb90629
commit a161bdac88
2 changed files with 11 additions and 0 deletions

View File

@ -100,6 +100,11 @@ public class UserHistoryDictIOUtils {
@Override
public int limit() {
return mBuffer.length - 1;
}
@Override
public int capacity() {
return mBuffer.length;
}
}

View File

@ -63,6 +63,7 @@ public class BinaryDictInputOutput {
public void position(int newPosition);
public void put(final byte b);
public int limit();
public int capacity();
}
public static final class ByteBufferWrapper implements FusionDictionaryBufferInterface {
@ -112,6 +113,11 @@ public class BinaryDictInputOutput {
public int limit() {
return mBuffer.limit();
}
@Override
public int capacity() {
return mBuffer.capacity();
}
}
/**