Searched defs:buffer (Results 1 - 25 of 36) sorted by relevance

12

/packages/apps/Nfc/nci/jni/
H A DDataQueue.cpp114 ** buffer: array to store the data.
115 ** bufferMaxLen: maximum size of the buffer.
121 bool DataQueue::dequeue (UINT8* buffer, UINT16 bufferMaxLen, UINT16& actualLen) argument
128 if (header && buffer && (bufferMaxLen>0))
132 //caller's buffer is big enough to store all data
135 memcpy (buffer, src, actualLen);
142 //caller's buffer is too small
145 memcpy (buffer, src, actualLen);
H A DRouteDataSet.h137 UINT8* buffer () {return mBuffer;}; function in class:AidBuffer
H A DRouteDataSet.cpp294 char buffer [1024]; local
307 actual = fread (buffer, sizeof(char), sizeof(buffer), fh);
310 routesXml.append (buffer, actual);
/packages/apps/Email/src/org/apache/james/mime4j/decoder/
H A DUnboundedFifoByteBuffer.java26 * UnboundedFifoByteBuffer is a very efficient buffer implementation.
44 * This buffer prevents null objects from being added.
57 protected byte[] buffer; field in class:UnboundedFifoByteBuffer
77 * @param initialSize the initial size of the buffer
84 buffer = new byte[initialSize + 1];
90 * Returns the number of elements stored in the buffer.
92 * @return this buffer's size
98 size = buffer.length - head + tail;
107 * Returns true if this buffer is empty; false otherwise.
109 * @return true if this buffer i
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
H A DNinePatchChunk.java37 private static void readIntArray(int[] data, ByteBuffer buffer) { argument
39 data[i] = buffer.getInt();
/packages/apps/Gallery2/src/com/android/gallery3d/util/
H A DInterruptableOutputStream.java43 public void write(byte[] buffer, int offset, int count) throws IOException { argument
48 mOutputStream.write(buffer, offset, bytesCount);
/packages/apps/Contacts/src/com/android/contacts/format/
H A DFormatUtils.java115 public static void copyToCharArrayBuffer(String text, CharArrayBuffer buffer) { argument
117 char[] data = buffer.data;
119 buffer.data = text.toCharArray();
123 buffer.sizeCopied = text.length();
125 buffer.sizeCopied = 0;
131 public static String charArrayBufferToString(CharArrayBuffer buffer) { argument
132 return new String(buffer.data, 0, buffer.sizeCopied);
/packages/apps/Contacts/tests/src/com/android/contacts/format/
H A DFormatUtilsTests.java46 // This requires a resize of the actual buffer.
58 CharArrayBuffer buffer = new CharArrayBuffer(20);
59 FormatUtils.copyToCharArrayBuffer(text, buffer);
60 assertEquals(text, FormatUtils.charArrayBufferToString(buffer));
64 * Checks that copying into the char array buffer copies the values correctly.
66 private void checkCopyToCharArrayBuffer(CharArrayBuffer buffer, String value, int length) { argument
67 FormatUtils.copyToCharArrayBuffer(value, buffer);
68 assertEquals(length, buffer.sizeCopied);
70 assertEquals(value.charAt(index), buffer.data[index]);
/packages/apps/Gallery2/src/com/android/gallery3d/data/
H A DBytesBufferPool.java79 public synchronized void recycle(BytesBuffer buffer) { argument
80 if (buffer.data.length != mBufferSize) return;
82 buffer.offset = 0;
83 buffer.length = 0;
84 mList.add(buffer);
H A DImageCacheService.java51 * The image data will be stored in <code>buffer.data</code>, started from
52 * <code>buffer.offset</code> for <code>buffer.length</code> bytes. If the
53 * buffer.data is not big enough, a new byte array will be allocated and returned.
57 public boolean getImageData(Path path, int type, BytesBuffer buffer) { argument
63 request.buffer = buffer.data;
67 if (isSameKey(key, request.buffer)) {
68 buffer.data = request.buffer;
110 isSameKey(byte[] key, byte[] buffer) argument
[all...]
/packages/apps/Camera/jni/feature_mos/src/mosaic_renderer/
H A DRenderer.cpp113 // Set this renderer to use the default frame-buffer (screen) and
146 bool Renderer::SetupGraphics(FrameBuffer* buffer) argument
160 glBindFramebuffer(GL_FRAMEBUFFER, buffer->GetFrameBufferName());
162 mFrameBuffer = buffer;
/packages/apps/LegacyCamera/jni/feature_mos/src/mosaic_renderer/
H A DRenderer.cpp113 // Set this renderer to use the default frame-buffer (screen) and
146 bool Renderer::SetupGraphics(FrameBuffer* buffer) argument
160 glBindFramebuffer(GL_FRAMEBUFFER, buffer->GetFrameBufferName());
162 mFrameBuffer = buffer;
/packages/apps/Mms/src/com/android/mms/util/
H A DImageCacheService.java79 ByteBuffer buffer = ByteBuffer.allocate(key.length + value.length);
80 buffer.put(key);
81 buffer.put(value);
84 mCache.insert(cacheKey, buffer.array());
99 private static boolean isSameKey(byte[] key, byte[] buffer) { argument
101 if (buffer.length < n) {
105 if (key[i] != buffer[i]) {
138 public static final long crc64Long(byte[] buffer) { argument
140 for (int k = 0, n = buffer.length; k < n; ++k) {
141 crc = sCrcTable[(((int) crc) ^ buffer[
[all...]
/packages/apps/Nfc/nxp/jni/
H A Dcom_android_nfc_NativeLlcpSocket.cpp187 serviceName.buffer = (uint8_t*)e->GetStringUTFChars(sn, NULL);
220 if (serviceName.buffer != NULL) {
221 e->ReleaseStringUTFChars(sn, (const char *)serviceName.buffer);
268 sSendBuffer.buffer = (uint8_t*)e->GetByteArrayElements(data, NULL);
301 if (sSendBuffer.buffer != NULL)
303 e->ReleaseByteArrayElements(data, (jbyte*)sSendBuffer.buffer, JNI_ABORT);
309 static jint com_android_nfc_NativeLlcpSocket_doReceive(JNIEnv *e, jobject o, jbyteArray buffer) argument
329 sReceiveBuffer.buffer = (uint8_t*)e->GetByteArrayElements(buffer, NULL);
330 sReceiveBuffer.length = (uint32_t)e->GetArrayLength(buffer);
[all...]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/makedict/
H A DBinaryDictIOUtils.java52 final FusionDictionaryBufferInterface buffer, final int headerSize,
72 if (buffer.position() != p.mAddress) buffer.position(p.mAddress);
76 p.mNumOfCharGroup = BinaryDictInputOutput.readCharGroupCount(buffer);
84 CharGroupInfo info = BinaryDictInputOutput.readCharGroup(buffer,
102 final int forwardLinkAddress = buffer.readUnsignedInt24();
115 p.mAddress = buffer.position();
129 * @param buffer the buffer to read.
136 public static void readUnigramsAndBigramsBinary(final FusionDictionaryBufferInterface buffer, argument
51 readUnigramsAndBigramsBinaryInner( final FusionDictionaryBufferInterface buffer, final int headerSize, final Map<Integer, String> words, final Map<Integer, Integer> frequencies, final Map<Integer, ArrayList<PendingAttribute>> bigrams, final FormatOptions formatOptions) argument
156 getTerminalPosition(final FusionDictionaryBufferInterface buffer, final String word) argument
239 deleteWord(final FusionDictionaryBufferInterface buffer, final String word) argument
253 putSInt24(final FusionDictionaryBufferInterface buffer, final int value) argument
269 updateParentAddress(final FusionDictionaryBufferInterface buffer, final int groupOriginAddress, final int newParentAddress, final FormatOptions formatOptions) argument
[all...]
/packages/apps/Bluetooth/src/com/android/bluetooth/opp/
H A DBluetoothOppObexClientSession.java113 private static int readFully(InputStream is, byte[] buffer, int size) throws IOException { argument
116 int got = is.read(buffer, done, size - done);
396 byte[] buffer = new byte[outputBufferSize];
400 readLength = readFully(a, buffer, outputBufferSize);
410 outputStream.write(buffer, 0, readLength);
420 // if file length is smaller than buffer size, only one packet
448 readLength = a.read(buffer, 0, outputBufferSize);
449 outputStream.write(buffer, 0, readLength);
/packages/apps/Email/src/org/apache/james/mime4j/field/address/parser/
H A DSimpleCharStream.java42 protected char[] buffer; field in class:SimpleCharStream
61 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
62 System.arraycopy(buffer, 0, newbuffer,
64 buffer = newbuffer;
78 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
79 buffer = newbuffer;
127 if ((i = inputStream.read(buffer, maxNextCharInd,
204 return buffer[bufpos];
210 char c = buffer[bufpos];
265 buffer
[all...]
/packages/apps/Email/src/org/apache/james/mime4j/field/contenttype/parser/
H A DSimpleCharStream.java42 protected char[] buffer; field in class:SimpleCharStream
61 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
62 System.arraycopy(buffer, 0, newbuffer,
64 buffer = newbuffer;
78 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
79 buffer = newbuffer;
127 if ((i = inputStream.read(buffer, maxNextCharInd,
204 return buffer[bufpos];
210 char c = buffer[bufpos];
265 buffer
[all...]
/packages/apps/Email/src/org/apache/james/mime4j/field/datetime/parser/
H A DSimpleCharStream.java42 protected char[] buffer; field in class:SimpleCharStream
61 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
62 System.arraycopy(buffer, 0, newbuffer,
64 buffer = newbuffer;
78 System.arraycopy(buffer, tokenBegin, newbuffer, 0, bufsize - tokenBegin);
79 buffer = newbuffer;
127 if ((i = inputStream.read(buffer, maxNextCharInd,
204 return buffer[bufpos];
210 char c = buffer[bufpos];
265 buffer
[all...]
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/exif/
H A DExifOutputStream.java57 private int requestByteToBuffer(int requestByteCount, byte[] buffer
61 mBuffer.put(buffer, offset, byteToRead);
66 public void write(byte[] buffer, int offset, int length) throws IOException { argument
77 out.write(buffer, offset, byteToProcess);
85 int byteRead = requestByteToBuffer(2, buffer, offset, length);
98 byteRead = requestByteToBuffer(4, buffer, offset, length);
126 out.write(buffer, offset, length);
137 public void write(byte[] buffer) throws IOException { argument
138 write(buffer, 0, buffer
[all...]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
H A DUserHistoryDictIOUtils.java58 public ByteArrayWrapper(final byte[] buffer) { argument
59 mBuffer = buffer;
175 public static void readDictionaryBinary(final FusionDictionaryBufferInterface buffer, argument
181 BinaryDictIOUtils.readUnigramsAndBigramsBinary(buffer, unigrams, frequencies,
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/research/
H A DResearchLog.java73 public void write(byte[] buffer, int offset, int count) { argument
79 public void write(byte[] buffer) { argument
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
H A DUtils.java154 public static final long crc64Long(byte[] buffer) { argument
156 for (int k = 0, n = buffer.length; k < n; ++k) {
157 crc = sCrcTable[(((int) crc) ^ buffer[k]) & 0xff] ^ (crc >> 8);
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/makedict/
H A DBinaryDictIOTests.java101 * Makes new buffer according to BUFFER_TYPE.
112 final ByteBuffer buffer = inStream.getChannel().map(
114 return new BinaryDictInputOutput.ByteBufferWrapper(buffer);
117 Log.e(TAG, "IOException while making buffer: " + e);
237 String result = " : buffer type = "
238 + ((bufferType == USE_BYTE_BUFFER) ? "byte buffer" : "byte array");
249 final FusionDictionaryBufferInterface buffer = getBuffer(file, bufferType);
250 assertNotNull(buffer);
255 dict = BinaryDictInputOutput.readDictionaryBinary(buffer, null);
385 final FusionDictionaryBufferInterface buffer
473 getWordFromBinary(final FusionDictionaryBufferInterface buffer, final int address) argument
490 runGetTerminalPosition(final FusionDictionaryBufferInterface buffer, final String word, int index, boolean contained) argument
[all...]
/packages/apps/Camera/jni/
H A Dfeature_mos_jni.cpp39 char buffer[1024]; variable
385 // Copy into HR buffer only if this is a valid frame

Completed in 8002 milliseconds

12