Lines Matching refs:count
51 int srcOffset, int destOffset, int count, boolean isUnpinned) throws IOException;
53 int srcOffset, int destOffset, int count, boolean isUnpinned) throws IOException;
194 * @param count number of bytes to read.
198 public int readBytes(byte[] buffer, int srcOffset, int destOffset, int count)
203 if (destOffset < 0 || destOffset > buffer.length || count < 0
204 || count > buffer.length - destOffset
206 || count > mLength - srcOffset) {
209 return native_read(mFD, mAddress, buffer, srcOffset, destOffset, count, mAllowPurging);
219 * @param count number of bytes to write.
222 public void writeBytes(byte[] buffer, int srcOffset, int destOffset, int count)
227 if (srcOffset < 0 || srcOffset > buffer.length || count < 0
228 || count > buffer.length - srcOffset
230 || count > mLength - destOffset) {
233 native_write(mFD, mAddress, buffer, srcOffset, destOffset, count, mAllowPurging);
303 public int read(byte buffer[], int offset, int count) throws IOException {
304 if (offset < 0 || count < 0 || offset + count > buffer.length) {
306 // changing count.
309 count = Math.min(count, available());
310 if (count < 1) {
313 int result = readBytes(buffer, mOffset, offset, count);
336 public void write(byte buffer[], int offset, int count) throws IOException {
337 writeBytes(buffer, offset, mOffset, count);
338 mOffset += count;