Searched defs:byteCount (Results 1 - 23 of 23) sorted by relevance

/libcore/luni/src/main/java/libcore/io/
H A DBufferIterator.java32 * Skips forwards or backwards {@code byteCount} bytes from the current position.
34 public abstract void skip(int byteCount); argument
37 * Copies {@code byteCount} bytes from the current position into {@code dst}, starting at
38 * {@code dstOffset}, and advances the current position {@code byteCount} bytes.
40 public abstract void readByteArray(byte[] dst, int dstOffset, int byteCount); argument
H A DNioBufferIterator.java44 public void skip(int byteCount) { argument
45 position += byteCount;
48 public void readByteArray(byte[] dst, int dstOffset, int byteCount) { argument
49 Memory.peekByteArray(address + position, dst, dstOffset, byteCount);
50 position += byteCount;
H A DStreams.java64 * Reads exactly 'byteCount' bytes from 'in' (into 'dst' at offset 'offset'), and throws
69 public static void readFully(InputStream in, byte[] dst, int offset, int byteCount) throws IOException { argument
70 if (byteCount == 0) {
79 Arrays.checkOffsetAndCount(dst.length, offset, byteCount);
80 while (byteCount > 0) {
81 int bytesRead = in.read(dst, offset, byteCount);
86 byteCount -= bytesRead;
138 * Skip <b>at most</b> {@code byteCount} bytes from {@code in} by calling read
149 public static long skipByReading(InputStream in, long byteCount) throws IOException { argument
157 while (skipped < byteCount) {
[all...]
H A DIoBridge.java465 public static int read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) throws IOException { argument
466 Arrays.checkOffsetAndCount(bytes.length, byteOffset, byteCount);
467 if (byteCount == 0) {
471 int readCount = Libcore.os.read(fd, bytes, byteOffset, byteCount);
489 public static void write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) throws IOException { argument
490 Arrays.checkOffsetAndCount(bytes.length, byteOffset, byteCount);
491 if (byteCount == 0) {
495 while (byteCount > 0) {
496 int bytesWritten = Libcore.os.write(fd, bytes, byteOffset, byteCount);
497 byteCount
505 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
548 recvfrom(boolean isRead, FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, DatagramPacket packet, boolean isConnected) argument
572 postRecvfrom(boolean isRead, DatagramPacket packet, boolean isConnected, InetSocketAddress srcAddress, int byteCount) argument
[all...]
H A DMemory.java35 public static native void unsafeBulkGet(Object dst, int dstOffset, int byteCount, argument
42 public static native void unsafeBulkPut(byte[] dst, int dstOffset, int byteCount, argument
142 * Copies 'byteCount' bytes from the source to the destination. The objects are either
151 public static native void memmove(Object dstObject, int dstOffset, Object srcObject, int srcOffset, long byteCount); argument
182 public static native void peekByteArray(long address, byte[] dst, int dstOffset, int byteCount); argument
H A DBlockGuardOs.java209 @Override public int pread(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException { argument
211 return os.pread(fd, bytes, byteOffset, byteCount, offset);
219 @Override public int pwrite(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException { argument
221 return os.pwrite(fd, bytes, byteOffset, byteCount, offset);
229 @Override public int read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) throws ErrnoException, InterruptedIOException { argument
231 return os.read(fd, bytes, byteOffset, byteCount);
254 @Override public int recvfrom(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetSocketAddress srcAddress) throws ErrnoException, SocketException { argument
256 return os.recvfrom(fd, bytes, byteOffset, byteCount, flags, srcAddress);
269 @Override public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { argument
271 return os.sendfile(outFd, inFd, inOffset, byteCount);
279 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
317 write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
[all...]
H A DForwardingOs.java111 public void mincore(long address, long byteCount, byte[] vector) throws ErrnoException { os.mincore(address, byteCount, vector); } argument
114 public void mlock(long address, long byteCount) throws ErrnoException { os.mlock(address, byteCount); } argument
115 public long mmap(long address, long byteCount, int prot, int flags, FileDescriptor fd, long offset) throws ErrnoException { return os.mmap(address, byteCount, prot, flags, fd, offset); } argument
116 public void msync(long address, long byteCount, int flags) throws ErrnoException { os.msync(address, byteCount, flags); } argument
117 public void munlock(long address, long byteCount) throws ErrnoException { os.munlock(address, byteCount); } argument
118 munmap(long address, long byteCount) argument
125 pread(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) argument
127 pwrite(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) argument
129 read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
134 recvfrom(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetSocketAddress srcAddress) argument
138 sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) argument
140 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
141 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, SocketAddress address) argument
177 write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
[all...]
H A DOs.java103 public void mincore(long address, long byteCount, byte[] vector) throws ErrnoException; argument
106 public void mlock(long address, long byteCount) throws ErrnoException; argument
107 public long mmap(long address, long byteCount, int prot, int flags, FileDescriptor fd, long offset) throws ErrnoException; argument
108 public void msync(long address, long byteCount, int flags) throws ErrnoException; argument
109 public void munlock(long address, long byteCount) throws ErrnoException; argument
110 public void munmap(long address, long byteCount) throws ErrnoException; argument
118 public int pread(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException; argument
120 public int pwrite(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException; argument
122 public int read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) throws ErrnoException, InterruptedIOException; argument
127 public int recvfrom(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, in argument
132 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
133 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, SocketAddress address) argument
134 sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) argument
170 write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
[all...]
H A DPosix.java105 public native void mincore(long address, long byteCount, byte[] vector) throws ErrnoException; argument
108 public native void mlock(long address, long byteCount) throws ErrnoException; argument
109 public native long mmap(long address, long byteCount, int prot, int flags, FileDescriptor fd, long offset) throws ErrnoException; argument
110 public native void msync(long address, long byteCount, int flags) throws ErrnoException; argument
111 public native void munlock(long address, long byteCount) throws ErrnoException; argument
112 public native void munmap(long address, long byteCount) throws ErrnoException; argument
131 public int pread(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException { argument
133 return preadBytes(fd, bytes, byteOffset, byteCount, offset);
135 private native int preadBytes(FileDescriptor fd, Object buffer, int bufferOffset, int byteCount, long offset) throws ErrnoException, InterruptedIOException; argument
149 public int pwrite(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, lon argument
153 pwriteBytes(FileDescriptor fd, Object buffer, int bufferOffset, int byteCount, long offset) argument
167 read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
171 readBytes(FileDescriptor fd, Object buffer, int offset, int byteCount) argument
188 recvfrom(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetSocketAddress srcAddress) argument
192 recvfromBytes(FileDescriptor fd, Object buffer, int byteOffset, int byteCount, int flags, InetSocketAddress srcAddress) argument
196 sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) argument
210 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
214 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, SocketAddress address) argument
217 sendtoBytes(FileDescriptor fd, Object buffer, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
218 sendtoBytes(FileDescriptor fd, Object buffer, int byteOffset, int byteCount, int flags, SocketAddress address) argument
271 write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
275 writeBytes(FileDescriptor fd, Object buffer, int offset, int byteCount) argument
[all...]
/libcore/luni/src/test/java/libcore/java/util/zip/
H A DDeflaterOutputStreamTest.java106 public int deflate(byte[] buf, int offset, int byteCount) { argument
107 return super.deflate(buf, offset, byteCount, Deflater.SYNC_FLUSH);
/libcore/libart/src/main/java/java/lang/
H A DStringFactory.java52 public static String newStringFromBytes(byte[] data, int offset, int byteCount) { argument
53 return newStringFromBytes(data, offset, byteCount, Charset.defaultCharset());
56 public static native String newStringFromBytes(byte[] data, int high, int offset, int byteCount); argument
58 public static String newStringFromBytes(byte[] data, int offset, int byteCount, String charsetName) throws UnsupportedEncodingException { argument
59 return newStringFromBytes(data, offset, byteCount, Charset.forNameUEE(charsetName));
67 public static String newStringFromBytes(byte[] data, int offset, int byteCount, Charset charset) { argument
68 if ((offset | byteCount) < 0 || byteCount > data.length - offset) {
69 throw new StringIndexOutOfBoundsException(data.length, offset, byteCount);
79 char[] v = new char[byteCount];
[all...]
/libcore/luni/src/test/java/libcore/javax/crypto/
H A DCipherInputStreamTest.java83 public int read(byte[] buffer, int byteOffset, int byteCount) throws IOException { argument
84 int numRead = super.read(buffer, byteOffset, byteCount);
/libcore/ojluni/src/main/native/
H A DCharacter.cpp159 int32_t byteCount = u_charName(codePoint, nameType, &buf[0], sizeof(buf), &status); local
160 return (U_FAILURE(status) || byteCount == 0) ? NULL : env->NewStringUTF(buf);
/libcore/support/src/test/java/tests/support/
H A DSupport_TestWebData.java47 private static byte[] newBinaryFile(int byteCount) { argument
48 byte[] result = new byte[byteCount];
/libcore/dex/src/main/java/com/android/dex/
H A DTableOfContents.java153 section.byteCount = end - section.off;
216 public int byteCount = 0; field in class:TableOfContents.Section
H A DDex.java87 public Dex(int byteCount) throws IOException { argument
88 this.data = ByteBuffer.wrap(new byte[byteCount]);
/libcore/luni/src/main/java/org/apache/harmony/security/provider/crypto/
H A DSHA1PRNG_SecureRandomImpl.java547 private static byte[] getRandomBytes(int byteCount) { argument
548 if (byteCount <= 0) {
549 throw new IllegalArgumentException("Too few bytes requested: " + byteCount);
555 byte[] result = new byte[byteCount];
556 Streams.readFully(devURandom, result, 0, byteCount);
559 throw new ProviderException("Couldn't read " + byteCount + " random bytes", ex);
/libcore/luni/src/test/java/libcore/java/security/cert/
H A DCertificateFactoryTest.java332 public long skip(long byteCount) throws IOException { argument
333 long count = mStream.skip(byteCount);
/libcore/luni/src/test/java/libcore/util/
H A DZoneInfoTest.java493 public void skip(int byteCount) { argument
494 buffer.position(buffer.position() + byteCount);
498 public void readByteArray(byte[] dst, int dstOffset, int byteCount) { argument
499 buffer.get(dst, dstOffset, byteCount);
/libcore/luni/src/main/native/
H A Dlibcore_io_Memory.cpp109 static void Memory_peekByteArray(JNIEnv* env, jclass, jlong srcAddress, jbyteArray dst, jint dstOffset, jint byteCount) { argument
110 env->SetByteArrayRegion(dst, dstOffset, byteCount, cast<const jbyte*>(srcAddress));
234 static void unsafeBulkCopy(jbyte* dst, const jbyte* src, jint byteCount, argument
237 memcpy(dst, src, byteCount);
244 swapShorts(dstShorts, srcShorts, byteCount / 2);
248 swapInts(dstInts, srcInts, byteCount / 4);
252 swapLongs(dstLongs, srcLongs, byteCount / 8);
257 jint byteCount, jbyteArray srcArray, jint srcOffset, jint sizeofElement, jboolean swap) {
269 unsafeBulkCopy(dst, src, byteCount, sizeofElement, swap);
274 jint byteCount, jobjec
256 Memory_unsafeBulkGet(JNIEnv* env, jclass, jobject dstObject, jint dstOffset, jint byteCount, jbyteArray srcArray, jint srcOffset, jint sizeofElement, jboolean swap) argument
273 Memory_unsafeBulkPut(JNIEnv* env, jclass, jbyteArray dstArray, jint dstOffset, jint byteCount, jobject srcObject, jint srcOffset, jint sizeofElement, jboolean swap) argument
[all...]
H A Dorg_apache_harmony_xml_ExpatParser.cpp428 static size_t fillBuffer(ParsingContext* parsingContext, const char* utf8, int byteCount) { argument
432 jcharArray javaChars = parsingContext->ensureCapacity(byteCount);
443 icu::UnicodeString utf16(icu::UnicodeString::fromUTF8(icu::StringPiece(utf8, byteCount)));
444 return utf16.extract(chars.get(), byteCount, status);
1019 const char* bytes, size_t byteOffset, size_t byteCount, jboolean isFinal) {
1024 if (!XML_Parse(parser, bytes + byteOffset, byteCount, isFinal) && !env->ExceptionCheck()) {
1032 jbyteArray xml, jint byteOffset, jint byteCount) {
1039 append(env, object, pointer, bytes, byteOffset, byteCount, XML_FALSE);
1051 size_t byteCount = 2 * charCount; local
1052 append(env, object, pointer, bytes, byteOffset, byteCount, XML_FALS
1018 append(JNIEnv* env, jobject object, jlong pointer, const char* bytes, size_t byteOffset, size_t byteCount, jboolean isFinal) argument
1031 ExpatParser_appendBytes(JNIEnv* env, jobject object, jlong pointer, jbyteArray xml, jint byteOffset, jint byteCount) argument
1061 size_t byteCount = 2 * xml.size(); local
[all...]
H A Dlibcore_io_Posix.cpp684 socklen_t byteCount = sizeof(ss); local
685 memset(&ss, 0, byteCount);
686 int rc = is_sockname ? TEMP_FAILURE_RETRY(getsockname(fd, sa, &byteCount))
687 : TEMP_FAILURE_RETRY(getpeername(fd, sa, &byteCount));
692 return makeSocketAddress(env, ss, byteCount);
1282 static void Posix_mincore(JNIEnv* env, jobject, jlong address, jlong byteCount, jbyteArray javaVector) { argument
1289 throwIfMinusOne(env, "mincore", TEMP_FAILURE_RETRY(mincore(ptr, byteCount, vec)));
1308 static void Posix_mlock(JNIEnv* env, jobject, jlong address, jlong byteCount) { argument
1310 throwIfMinusOne(env, "mlock", TEMP_FAILURE_RETRY(mlock(ptr, byteCount)));
1313 static jlong Posix_mmap(JNIEnv* env, jobject, jlong address, jlong byteCount, jin argument
1323 Posix_msync(JNIEnv* env, jobject, jlong address, jlong byteCount, jint flags) argument
1328 Posix_munlock(JNIEnv* env, jobject, jlong address, jlong byteCount) argument
1333 Posix_munmap(JNIEnv* env, jobject, jlong address, jlong byteCount) argument
1468 Posix_preadBytes(JNIEnv* env, jobject, jobject javaFd, jobject javaBytes, jint byteOffset, jint byteCount, jlong offset) argument
1476 Posix_pwriteBytes(JNIEnv* env, jobject, jobject javaFd, jbyteArray javaBytes, jint byteOffset, jint byteCount, jlong offset) argument
1484 Posix_readBytes(JNIEnv* env, jobject, jobject javaFd, jobject javaBytes, jint byteOffset, jint byteCount) argument
1529 Posix_recvfromBytes(JNIEnv* env, jobject, jobject javaFd, jobject javaBytes, jint byteOffset, jint byteCount, jint flags, jobject javaInetSocketAddress) argument
1582 Posix_sendfile(JNIEnv* env, jobject, jobject javaOutFd, jobject javaInFd, jobject javaOffset, jlong byteCount) argument
1600 Posix_sendtoBytes(JNIEnv* env, jobject, jobject javaFd, jobject javaBytes, jint byteOffset, jint byteCount, jint flags, jobject javaInetAddress, jint port) argument
1610 Posix_sendtoBytesSocketAddress(JNIEnv* env, jobject, jobject javaFd, jobject javaBytes, jint byteOffset, jint byteCount, jint flags, jobject javaSocketAddress) argument
1944 Posix_writeBytes(JNIEnv* env, jobject, jobject javaFd, jbyteArray javaBytes, jint byteOffset, jint byteCount) argument
[all...]
/libcore/luni/src/main/java/android/system/
H A DOs.java277 public static void mincore(long address, long byteCount, byte[] vector) throws ErrnoException { Libcore.os.mincore(address, byteCount, vector); } argument
292 public static void mlock(long address, long byteCount) throws ErrnoException { Libcore.os.mlock(address, byteCount); } argument
297 public static long mmap(long address, long byteCount, int prot, int flags, FileDescriptor fd, long offset) throws ErrnoException { return Libcore.os.mmap(address, byteCount, prot, flags, fd, offset); } argument
302 public static void msync(long address, long byteCount, int flags) throws ErrnoException { Libcore.os.msync(address, byteCount, flags); } argument
307 public static void munlock(long address, long byteCount) throws ErrnoException { Libcore.os.munlock(address, byteCount); } argument
312 munmap(long address, long byteCount) argument
353 pread(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) argument
363 pwrite(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, long offset) argument
373 read(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
393 recvfrom(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetSocketAddress srcAddress) argument
410 sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) argument
420 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, InetAddress inetAddress, int port) argument
425 sendto(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount, int flags, SocketAddress address) argument
571 write(FileDescriptor fd, byte[] bytes, int byteOffset, int byteCount) argument
[all...]

Completed in 626 milliseconds