Searched defs:bytes (Results 1 - 25 of 60) sorted by relevance

123

/frameworks/base/core/java/com/google/android/mms/pdu/
H A DQuotedPrintable.java26 * Decodes an array quoted-printable characters into an array of original bytes.
35 * @param bytes array of quoted-printable characters
36 * @return array of original bytes,
39 public static final byte[] decodeQuotedPrintable(byte[] bytes) { argument
40 if (bytes == null) {
44 for (int i = 0; i < bytes.length; i++) {
45 int b = bytes[i];
48 if('\r' == (char)bytes[i + 1] &&
49 '\n' == (char)bytes[i + 2]) {
53 int u = Character.digit((char) bytes[
[all...]
/frameworks/av/drm/common/
H A DReadWriteUtils.cpp46 char* bytes = new char[length]; local
47 if (length == read(fd, (void*) bytes, length)) {
48 string.append(bytes, length);
50 delete bytes;
/frameworks/base/core/java/com/android/internal/http/multipart/
H A DByteArrayPartSource.java50 private byte[] bytes; field in class:ByteArrayPartSource
55 * @param fileName the name of the file these bytes represent
56 * @param bytes the content of this part
58 public ByteArrayPartSource(String fileName, byte[] bytes) { argument
61 this.bytes = bytes;
69 return bytes.length;
83 return new ByteArrayInputStream(bytes);
/frameworks/base/tests/CoreTests/android/core/
H A DSha1Test.java56 private static String encodeHex(byte[] bytes) { argument
57 StringBuffer hex = new StringBuffer(bytes.length * 2);
59 for (int i = 0; i < bytes.length; i++) {
60 if (((int) bytes[i] & 0xff) < 0x10) {
63 hex.append(Integer.toString((int) bytes[i] & 0xff, 16));
/frameworks/base/core/java/com/android/internal/util/
H A DCharSequences.java26 * bytes.
28 * @param bytes ASCII bytes
30 public static CharSequence forAsciiBytes(final byte[] bytes) { argument
33 return (char) bytes[index];
37 return bytes.length;
41 return forAsciiBytes(bytes, start, end);
45 return new String(bytes);
52 * bytes.
54 * @param bytes ASCI
61 forAsciiBytes(final byte[] bytes, final int start, final int end) argument
[all...]
/frameworks/base/media/mca/filterfw/jni/
H A Djni_vertex_frame.cpp76 jbyte* bytes = env->GetByteArrayElements(data, NULL); local
77 if (bytes) {
78 const bool success = frame->WriteData(reinterpret_cast<const uint8_t*>(bytes + offset),
80 env->ReleaseByteArrayElements(data, bytes, JNI_ABORT);
/frameworks/base/voip/jni/rtp/
H A DGsmCodec.cpp62 unsigned char *bytes = (unsigned char *)payload; local
65 gsm_decode(mDecode, bytes, &samples[n]) == 0) {
68 bytes += 33;
H A DAmrCodec.cpp102 unsigned char *bytes = (unsigned char *)payload; local
106 samples, bytes + 1, &type, AMR_TX_WMF);
113 bytes[0] = 0xF0;
114 bytes[1] = (mMode << 3) | 0x04;
118 bytes[0] = 0xFF;
119 bytes[1] = 0xC0 | (mMode << 1) | 1;
122 bytes[length + 1] = 0;
124 bytes[i] = (bytes[i] << 6) | (bytes[
133 unsigned char *bytes = (unsigned char *)payload; local
226 unsigned char *bytes = (unsigned char *)payload; local
244 unsigned char *bytes = (unsigned char *)payload; local
[all...]
/frameworks/av/include/media/stagefright/
H A DMediaWriter.h41 virtual void setMaxFileSize(int64_t bytes) { mMaxFileSizeLimitBytes = bytes; } argument
/frameworks/base/core/jni/
H A Dandroid_ddm_DdmHandleNativeHeap.cpp90 ALOGD("**** read %d bytes from '%s'", (int) header.mapSize, path);
98 jbyte* bytes = NULL; local
105 bytes = env->GetByteArrayElements(array, NULL);
106 ptr = bytes;
120 env->ReleaseByteArrayElements(array, bytes, 0);
H A Dandroid_hardware_UsbDeviceConnection.cpp98 jbyte* bytes = (jbyte*)env->GetPrimitiveArrayCritical(ret, 0); local
99 if (bytes) {
100 memcpy(bytes, buffer, length);
101 env->ReleasePrimitiveArrayCritical(ret, bytes, 0);
/frameworks/rs/
H A DrsFifoSocket.cpp54 bool FifoSocket::writeAsync(const void *data, size_t bytes, bool waitForSpace) { argument
55 if (bytes == 0) {
58 //ALOGE("writeAsync %p %i", data, bytes);
59 size_t ret = ::send(sv[0], data, bytes, 0);
61 rsAssert(ret == bytes);
76 size_t FifoSocket::read(void *data, size_t bytes) { argument
81 //ALOGE("read %p %i", data, bytes);
82 size_t ret = ::recv(sv[1], data, bytes, MSG_WAITALL);
83 rsAssert(ret == bytes || mShutdown);
84 //ALOGE("read ret %i bytes
101 readReturn(const void *data, size_t bytes) argument
[all...]
H A DrsThreadIO.h73 uint32_t bytes; member in struct:android::renderscript::ThreadIO::CoreCmdHeaderRec
77 uint32_t bytes; member in struct:android::renderscript::ThreadIO::ClientCmdHeaderRec
H A DrsStream.h87 void align(uint32_t bytes) { argument
88 mPos = (mPos + (bytes - 1)) & (~(bytes - 1));
/frameworks/base/core/java/android/speech/tts/
H A DSynthesisPlaybackQueueItem.java240 ListEntry(byte[] bytes) { argument
241 mBytes = bytes;
H A DBlockingAudioTrack.java56 * A "short utterance" is one that uses less bytes than the audio
173 private static int writeToAudioTrack(AudioTrack audioTrack, byte[] bytes) { argument
180 while (count < bytes.length) {
183 int written = audioTrack.write(bytes, count, bytes.length);
/frameworks/base/keystore/java/android/security/
H A DCredentials.java127 public static List<Object> convertFromPem(byte[] bytes) throws IOException { argument
128 ByteArrayInputStream bai = new ByteArrayInputStream(bytes);
H A DKeyChain.java146 * encoded bytes with {@link X509Certificate#getEncoded}.
157 * install. The extra value should be a {@code byte[]}. The bytes
195 * #EXTRA_PKCS12} maybe used to specify the bytes of an X.509
369 private static X509Certificate toCertificate(byte[] bytes) { argument
370 if (bytes == null) {
371 throw new IllegalArgumentException("bytes == null");
375 Certificate cert = certFactory.generateCertificate(new ByteArrayInputStream(bytes));
/frameworks/base/telephony/java/com/android/internal/telephony/
H A DIccUtils.java151 * shall be left justified. Unused bytes shall be set to 'FF'; or
309 * @param bytes an array of bytes
311 * @return hex string representation of bytes array
314 bytesToHexString(byte[] bytes) { argument
315 if (bytes == null) return null;
317 StringBuilder ret = new StringBuilder(2*bytes.length);
319 for (int i = 0 ; i < bytes.length ; i++) {
322 b = 0x0f & (bytes[i] >> 4);
326 b = 0x0f & bytes[
[all...]
/frameworks/base/tests/DumpRenderTree2/src/com/android/dumprendertree2/
H A DFsUtils.java91 public static void writeDataToStorage(File file, byte[] bytes, boolean append) { argument
100 outputStream.write(bytes);
119 byte[] bytes = null;
124 bytes = new byte[(int)file.length()];
125 fis.read(bytes);
135 return bytes;
/frameworks/native/include/utils/
H A DString8.h60 inline size_t bytes() const;
266 inline size_t String8::bytes() const function in class:android::String8
/frameworks/av/media/libstagefright/
H A DAudioSource.cpp189 uint8_t *data, size_t bytes) {
194 int32_t stopFrame = startFrame + bytes / sizeof(int16_t);
309 // Convert number of frames lost to number of bytes lost.
318 ALOGW("Lost audio record data: %d bytes", numLostBytes);
187 rampVolume( int32_t startFrame, int32_t rampDurationFrames, uint8_t *data, size_t bytes) argument
/frameworks/av/media/libstagefright/codecs/flac/enc/
H A DSoftFlacEncoder.cpp332 size_t bytes, unsigned samples, unsigned current_frame) {
333 ALOGV("SoftFlacEncoder::onEncodedFlacAvailable(bytes=%d, samples=%d, curr_frame=%d)",
334 bytes, samples, current_frame);
338 ALOGI(" saving %d bytes of header", bytes);
339 memcpy(mHeader + mHeaderOffset, buffer, bytes);
340 mHeaderOffset += bytes;// will contain header size when finished receiving header
349 ALOGV("ignoring %d bytes of header data (samples=%d)", bytes, samples);
360 ALOGI(" writing %d bytes o
330 onEncodedFlacAvailable( const FLAC__byte buffer[], size_t bytes, unsigned samples, unsigned current_frame) argument
429 flacEncoderWriteCallback( const FLAC__StreamEncoder *encoder, const FLAC__byte buffer[], size_t bytes, unsigned samples, unsigned current_frame, void *client_data) argument
[all...]
/frameworks/base/core/java/android/net/http/
H A DSslCertificate.java124 byte[] bytes = bundle.getByteArray(X509_CERTIFICATE);
125 if (bytes == null) {
130 Certificate cert = certFactory.generateCertificate(new ByteArrayInputStream(bytes));
270 byte[] bytes = x509Certificate.getEncoded();
272 byte[] digest = md.digest(bytes);
281 private static final String fingerprint(byte[] bytes) { argument
282 if (bytes == null) {
286 for (int i = 0; i < bytes.length; i++) {
287 byte b = bytes[i];
289 if (i+1 != bytes
[all...]
/frameworks/base/core/java/com/android/internal/os/
H A DLoggingPrintStream.java41 * A buffer that is initialized when raw bytes are first written to this
42 * stream. It may contain the leading bytes of multi-byte characters.
49 * A buffer that is initialized when raw bytes are first written to this
56 * Decodes bytes to characters using the system default charset. Initialized
57 * when raw bytes are first written to this stream.
120 public synchronized void write(byte bytes[], int start, int count) { argument
131 // copy some bytes from the array to the long-lived buffer. This
134 encodedBytes.put(bytes, start, numBytes);
140 // decode bytes from the byte buffer into the char buffer

Completed in 361 milliseconds

123