Searched refs:buf (Results 1 - 25 of 56) sorted by relevance

123

/packages/apps/Email/emailcommon/src/org/apache/james/mime4j/decoder/
H A DByteQueue.java26 private UnboundedFifoByteBuffer buf; field in class:ByteQueue
30 buf = new UnboundedFifoByteBuffer();
34 buf = new UnboundedFifoByteBuffer(initialCapacity);
39 buf.add(b);
43 return buf.remove();
47 return buf.size();
52 buf = new UnboundedFifoByteBuffer(initialCapacity);
54 buf = new UnboundedFifoByteBuffer();
58 return buf.iterator();
/packages/apps/Email/emailcommon/src/org/apache/james/mime4j/field/address/
H A DGroup.java58 StringBuffer buf = new StringBuffer();
59 buf.append(name);
60 buf.append(":");
62 buf.append(mailboxList.get(i).toString());
64 buf.append(",");
66 buf.append(";");
67 return buf.toString();
/packages/apps/Gallery2/src/com/android/gallery3d/data/
H A DExif.java32 byte[] buf = new byte[8];
36 while (read(is, buf, 2) && (buf[0] & 0xFF) == 0xFF) {
37 int marker = buf[1] & 0xFF;
54 if (!read(is, buf, 2)) {
57 length = pack(buf, 0, 2, false);
66 if (!read(is, buf, 6)) return 0;
68 if (pack(buf, 0, 4, false) == 0x45786966 &&
69 pack(buf, 4, 2, false) == 0) {
154 private static boolean read(InputStream is, byte[] buf, in argument
[all...]
H A DClusterAlbum.java81 final MediaItem[] buf = new MediaItem[end - start];
84 buf[index] = item;
89 for (int i = 0; i < buf.length; i++) {
90 result.add(buf[i]);
H A DFilterSet.java102 final Path[] buf = new Path[total];
109 buf[index] = path;
115 if (buf[i] != null) {
116 mPaths.add(buf[i]);
/packages/inputmethods/LatinIME/native/src/
H A Ddebug.h62 unsigned char *buf = (unsigned char*)malloc((1 + codesSize) * sizeof(*buf)); local
64 buf[codesSize] = 0;
66 buf[codesSize] = (unsigned char)codes[codesSize * MAX_PROXIMITY_CHARS];
67 LOGI("%s, WORD = %s", tag, buf);
69 free(buf);
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
H A DBlobCache.java195 byte[] buf = mIndexHeader;
196 if (mIndexFile.read(buf) != INDEX_HEADER_SIZE) {
201 if (readInt(buf, IH_MAGIC) != MAGIC_INDEX_FILE) {
206 if (readInt(buf, IH_VERSION) != mVersion) {
211 mMaxEntries = readInt(buf, IH_MAX_ENTRIES);
212 mMaxBytes = readInt(buf, IH_MAX_BYTES);
213 mActiveRegion = readInt(buf, IH_ACTIVE_REGION);
214 mActiveEntries = readInt(buf, IH_ACTIVE_ENTRIES);
215 mActiveBytes = readInt(buf, IH_ACTIVE_BYTES);
217 int sum = readInt(buf, IH_CHECKSU
626 readInt(byte[] buf, int offset) argument
633 readLong(byte[] buf, int offset) argument
641 writeInt(byte[] buf, int offset, int value) argument
648 writeLong(byte[] buf, int offset, long value) argument
[all...]
/packages/apps/Gallery2/tests/src/com/android/gallery3d/util/
H A DIntArrayTest.java44 int[] buf = new int[2];
45 int[] result = a.toArray(buf);
46 assertSame(buf, result);
54 result = b.toArray(buf);
/packages/apps/Camera/jni/feature_mos/src/mosaic_renderer/
H A DRenderer.cpp49 char* buf = (char*) malloc(infoLen); local
50 if (buf) {
51 glGetShaderInfoLog(shader, infoLen, NULL, buf);
53 shaderType, buf);
54 free(buf);
98 char* buf = (char*) malloc(bufLength); local
99 if (buf)
101 glGetProgramInfoLog(program, bufLength, NULL, buf);
102 LOGE("Could not link program:\n%s\n", buf);
103 free(buf);
[all...]
/packages/apps/Phone/src/com/android/phone/
H A DDeleteFdnContactScreen.java102 StringBuilder buf = new StringBuilder();
104 buf.append("number='");
106 buf.append("tag='");
107 buf.append(mName);
108 buf.append("' AND number='");
110 buf.append(mNumber);
111 buf.append("' AND pin2='");
112 buf.append(mPin2);
113 buf.append("'");
118 mQueryHandler.startDelete(0, null, uri, buf
[all...]
/packages/apps/Mms/src/com/android/mms/ui/
H A DConversationListItem.java107 SpannableStringBuilder buf = new SpannableStringBuilder(from);
110 int before = buf.length();
111 buf.append(mContext.getResources().getString(R.string.message_count_format,
113 buf.setSpan(new ForegroundColorSpan(
115 before, buf.length(), Spannable.SPAN_INCLUSIVE_EXCLUSIVE);
118 buf.append(mContext.getResources().getString(R.string.draft_separator));
119 int before = buf.length();
121 buf.append(mContext.getResources().getString(R.string.has_draft));
123 buf.setSpan(new TextAppearanceSpan(mContext, size, color), before,
124 buf
[all...]
/packages/apps/Gallery2/tests/src/com/android/gallery3d/common/
H A DBlobCacheTest.java37 byte[] buf = new byte[9];
38 assertEquals(0, BlobCache.readInt(buf, 0));
39 assertEquals(0, BlobCache.readLong(buf, 0));
40 buf[0] = 1;
41 assertEquals(1, BlobCache.readInt(buf, 0));
42 assertEquals(1, BlobCache.readLong(buf, 0));
43 buf[3] = 0x7f;
44 assertEquals(0x7f000001, BlobCache.readInt(buf, 0));
45 assertEquals(0x7f000001, BlobCache.readLong(buf, 0));
46 assertEquals(0x007f0000, BlobCache.readInt(buf,
[all...]
/packages/apps/CellBroadcastReceiver/src/com/android/cellbroadcastreceiver/
H A DCellBroadcastListItem.java89 SpannableStringBuilder buf = new SpannableStringBuilder(body);
93 buf.setSpan(STYLE_BOLD, 0, buf.length(),
96 return buf;
/packages/apps/Mms/tests/src/com/android/mms/util/
H A DSmileyParserUnitTests.java50 SpannableStringBuilder buf = new SpannableStringBuilder();
53 buf.append(parser.addSmileySpans(":-):-:-("));
55 ImageSpan[] spans = buf.getSpans(0, buf.length(), ImageSpan.class);
/packages/apps/Email/emailcommon/src/org/apache/commons/io/output/
H A DByteArrayOutputStream.java252 byte[] buf = getBuffer(i);
253 int c = Math.min(buf.length, remaining);
254 out.write(buf, 0, c);
277 byte[] buf = getBuffer(i);
278 int c = Math.min(buf.length, remaining);
279 System.arraycopy(buf, 0, newbuf, pos, c);
/packages/inputmethods/OpenWnn/libs/libwnnDictionary/engine/
H A Dneapi.c70 NJ_EXTERN NJ_INT16 njx_get_candidate(NJ_CLASS *iwnn, NJ_RESULT *result, NJ_CHAR *buf, NJ_UINT16 buf_size) { argument
82 if ((buf == NULL) || (buf_size == 0)) {
88 ret = njd_get_candidate(iwnn, result, buf, buf_size);
100 NJ_EXTERN NJ_INT16 njx_get_stroke(NJ_CLASS *iwnn, NJ_RESULT *result, NJ_CHAR *buf, NJ_UINT16 buf_size) { argument
112 if ((buf == NULL) || (buf_size == 0)) {
118 ret = njd_get_stroke(iwnn, result, buf, buf_size);
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/deprecated/voice/
H A DWaveformImage.java49 final ShortBuffer buf = ByteBuffer
53 buf.position(0);
80 final short s = buf.get(index);
/packages/experimental/procstatlog/
H A Dprocstatlog.c73 char buf[4096]; local
81 int len = read(fd, buf, sizeof(buf));
90 while (len > 0 && isspace(buf[len - 1])) --len;
92 memcpy(data->value, buf, len);
106 char buf[8192]; local
110 int len = read(fd, buf, sizeof(buf) - 1);
116 buf[len] = '\0';
120 char *end = strstr(buf, terminato
161 char buf[8192]; local
[all...]
/packages/apps/Nfc/jni/
H A Dcom_android_nfc_NativeP2pDevice.cpp273 uint8_t *buf; local
292 buf = (uint8_t *)e->GetByteArrayElements(data, NULL);
297 transceive_info.sSendData.buffer = buf; //+ offset;
360 jbyteArray buf = NULL; local
398 buf = e->NewByteArray(data->length);
399 e->SetByteArrayRegion(buf, 0, data->length, (jbyte *)data->buffer);
404 return buf;
408 JNIEnv *e, jobject o, jbyteArray buf)
428 data.length = (uint32_t)e->GetArrayLength(buf);
429 data.buffer = (uint8_t *)e->GetByteArrayElements(buf, NUL
407 com_android_nfc_NativeP2pDevice_doSend( JNIEnv *e, jobject o, jbyteArray buf) argument
[all...]
H A Dcom_android_nfc_NativeNfcTag.cpp180 jbyteArray buf = NULL; local
222 buf = e->NewByteArray(nfc_jni_ndef_rw.length);
223 e->SetByteArrayRegion(buf, 0, nfc_jni_ndef_rw.length,
230 return buf;
235 jobject o, jbyteArray buf)
251 nfc_jni_ndef_rw.length = (uint32_t)e->GetArrayLength(buf);
252 nfc_jni_ndef_rw.buffer = (uint8_t *)e->GetByteArrayElements(buf, NULL);
282 e->ReleaseByteArrayElements(buf, (jbyte *)nfc_jni_ndef_rw.buffer, JNI_ABORT);
712 // buf is the pointer to the JNI array and never overwritten,
715 uint8_t *buf local
234 com_android_nfc_NativeNfcTag_doWrite(JNIEnv *e, jobject o, jbyteArray buf) argument
[all...]
/packages/apps/Settings/src/com/android/settings/
H A DDateTimeSettings.java381 char[] buf = new char[9];
382 buf[0] = 'G';
383 buf[1] = 'M';
384 buf[2] = 'T';
387 buf[3] = '-';
390 buf[3] = '+';
396 buf[4] = (char) ('0' + hours / 10);
397 buf[5] = (char) ('0' + hours % 10);
399 buf[6] = ':';
401 buf[
[all...]
/packages/apps/Email/emailcommon/src/org/apache/commons/io/
H A DFileSystemUtils.java286 StringBuffer buf = new StringBuffer(line.substring(bytesStart, bytesEnd));
287 for (int k = 0; k < buf.length(); k++) {
288 if (buf.charAt(k) == ',' || buf.charAt(k) == '.') {
289 buf.deleteCharAt(k--);
292 return parseBytes(buf.toString(), path);
/packages/apps/Browser/src/com/android/browser/homepages/
H A DRequestHandler.java127 byte[] buf = new byte[4096];
129 while ((read = in.read(buf)) > 0) {
130 mOutput.write(buf, 0, read);
/packages/providers/DownloadProvider/src/com/android/providers/downloads/
H A DDrmConvertSession.java88 byte[] buf = new byte[size];
89 System.arraycopy(inBuffer, 0, buf, 0, size);
90 convertedStatus = mDrmClient.convertData(mConvertSessionId, buf);
/packages/apps/Browser/src/com/android/browser/
H A DBrowserBackupAgent.java190 byte[] buf = new byte[CHUNK];
196 int numRead = data.readEntityData(buf, 0, CHUNK);
197 crc.update(buf, 0, numRead);
198 out.write(buf, 0, numRead);

Completed in 757 milliseconds

123