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

12

/packages/apps/UnifiedEmail/src/com/android/mail/lib/base/
H A DByteArrays.java32 * {@code 2 * bytes.length} characters long.
34 public static String toHexString(byte[] bytes) { argument
35 StringBuilder sb = new StringBuilder(2 * bytes.length);
36 for (byte b : bytes) {
/packages/apps/UnifiedEmail/src/com/google/android/mail/common/base/
H A DByteArrays.java33 * {@code 2 * bytes.length} characters long.
35 public static String toHexString(byte[] bytes) { argument
36 StringBuilder sb = new StringBuilder(2 * bytes.length);
37 for (byte b : bytes) {
/packages/apps/Camera2/src/com/android/camera/exif/
H A DByteBufferInputStream.java39 public int read(byte[] bytes, int off, int len) { argument
45 mBuf.get(bytes, off, len);
/packages/apps/CertInstaller/src/com/android/certinstaller/
H A DUtil.java45 static <T> T fromBytes(byte[] bytes) { argument
46 if (bytes == null) return null;
49 new ObjectInputStream(new ByteArrayInputStream(bytes));
57 static String toMd5(byte[] bytes) { argument
61 algorithm.update(bytes);
70 private static String toHexString(byte[] bytes, String separator) { argument
72 for (byte b : bytes) {
H A DCredentialHelper.java92 byte[] bytes = bundle.getByteArray(key);
93 Log.d(TAG, " " + key + ": " + ((bytes == null) ? -1 : bytes.length));
94 mBundle.put(key, bytes);
123 byte[] bytes = savedStates.getByteArray(Credentials.USER_PRIVATE_KEY);
124 if (bytes != null) {
125 setPrivateKey(bytes);
138 private void parseCert(byte[] bytes) { argument
139 if (bytes == null) {
147 new ByteArrayInputStream(bytes));
199 setPrivateKey(byte[] bytes) argument
[all...]
/packages/apps/ContactsCommon/src/com/android/contacts/common/util/
H A DBitmapUtil.java32 public static int getSmallerExtentFromBytes(byte[] bytes) { argument
37 BitmapFactory.decodeByteArray(bytes, 0, bytes.length, options);
73 public static Bitmap decodeBitmapFromBytes(byte[] bytes, int sampleSize) { argument
81 return BitmapFactory.decodeByteArray(bytes, 0, bytes.length, options);
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/exif/
H A DByteBufferInputStream.java39 public int read(byte[] bytes, int off, int len) { argument
45 mBuf.get(bytes, off, len);
/packages/apps/Launcher3/WallpaperPicker/src/com/android/gallery3d/exif/
H A DByteBufferInputStream.java39 public int read(byte[] bytes, int off, int len) { argument
45 mBuf.get(bytes, off, len);
/packages/apps/LegacyCamera/src/com/android/camera/
H A DExif.java121 private static int pack(byte[] bytes, int offset, int length, argument
131 value = (value << 8) | (bytes[offset] & 0xFF);
/packages/apps/Mms/src/com/android/mms/exif/
H A DByteBufferInputStream.java39 public int read(byte[] bytes, int off, int len) { argument
45 mBuf.get(bytes, off, len);
/packages/apps/Tag/canon/src/com/android/apps/tagcanon/
H A DTagCanon.java110 public TagDescription(String title, byte[] bytes) { argument
113 msgs = new NdefMessage[] { new NdefMessage(bytes) };
/packages/apps/UnifiedEmail/src/org/apache/commons/io/input/
H A DNullInputStream.java34 * large numbers of bytes - significantly speeding up
52 * protected void processBytes(byte[] bytes, int offset, int length) {
54 * bytes[i] = ... // set array value here
119 * Return the number of bytes that can be read.
121 * @return The number of bytes that can be read.
149 * @param readlimit The number of bytes before this marked position
192 * Read some bytes into the specified array.
194 * @param bytes The byte array to read into
195 * @return The number of bytes read or <code>-1</code>
202 public int read(byte[] bytes) throw argument
219 read(byte[] bytes, int offset, int length) argument
309 processBytes(byte[] bytes, int offset, int length) argument
[all...]
/packages/apps/Browser/tests/src/com/android/browser/
H A DWebStorageSizeManagerUnitTests.java77 private long bytes(double megabytes) { method in class:WebStorageSizeManagerUnitTests
88 mDiskInfo.setTotalSizeBytes(bytes(75));
89 mDiskInfo.setFreeSpaceSizeBytes(bytes(24));
97 long origin1EstimatedSize = bytes(3.5);
105 long origin2EstimatedSize = bytes(2.5);
128 long origin3EstimatedSize = bytes(5);
146 manager.onExceededDatabaseQuota("4", "4", 0, bytes(1), totalUsedQuota, mQuotaUpdater);
150 mAppCacheInfo.setAppCacheSizeBytes(bytes(2));
152 manager.onReachedMaxAppCacheSize(bytes(2), totalUsedQuota, mQuotaUpdater);
160 manager.onReachedMaxAppCacheSize(bytes(1.
[all...]
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
H A DFingerprint.java43 // 16 bytes for 128-bit fingerprint
61 // md5 digest bytes.
67 public Fingerprint(byte[] bytes) { argument
68 if ((bytes == null) || (bytes.length != FINGERPRINT_BYTE_LENGTH)) {
71 mMd5Digest = bytes;
87 byte[] bytes = new byte[8192];
90 int n = in.read(bytes);
111 // decode the hex bytes of the fingerprint portion
112 byte[] bytes
180 appendHexFingerprint(StringBuilder sb, byte[] bytes) argument
[all...]
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/jpegstream/
H A DJPEGInputStream.java188 native private int skipDecodedBytes(int bytes); argument
/packages/apps/Gallery2/jni_jpegstream/src/
H A Djpeg_reader.cpp117 int32_t JpegReader::read(int8_t* bytes, int32_t offset, int32_t count) { argument
135 if (bytes != NULL) {
136 // Treat NULL bytes as a skip
137 memcpy((void*) (bytes + offset), (void*) mScanlineIter,
145 if (bytes != NULL) {
146 // Treat NULL bytes as a skip
147 memcpy((void*) (bytes + offset), (void*) mScanlineIter,
149 bytes += mScanlineBytesRemaining;
H A Djpeg_writer.cpp116 int32_t JpegWriter::write(int8_t* bytes, int32_t length) { argument
127 if (length < 0 || bytes == NULL) {
136 memcpy((void*) mScanlineIter, (void*) bytes,
143 memcpy((void*) mScanlineIter, (void*) bytes,
145 bytes += mScanlineBytesRemaining;
H A Djpegstream.cpp277 jint bytes) {
278 if (bytes <= 0) {
290 skip = r_ptr->read(NULL, 0, bytes);
276 InputStream_skipDecodedBytes(JNIEnv* env, jobject thiz, jint bytes) argument
/packages/apps/Gallery2/src/com/android/gallery3d/data/
H A DDecodeUtils.java78 public static Bitmap decode(JobContext jc, byte[] bytes, Options options) { argument
79 return decode(jc, bytes, 0, bytes.length, options);
82 public static Bitmap decode(JobContext jc, byte[] bytes, int offset, argument
88 BitmapFactory.decodeByteArray(bytes, offset, length, options));
91 public static void decodeBounds(JobContext jc, byte[] bytes, int offset, argument
96 BitmapFactory.decodeByteArray(bytes, offset, length, options);
200 JobContext jc, byte[] bytes, int offset, int length,
202 if (offset < 0 || length <= 0 || offset + length > bytes.length) {
204 "offset = %s, length = %s, bytes
199 createBitmapRegionDecoder( JobContext jc, byte[] bytes, int offset, int length, boolean shareable) argument
[all...]
/packages/apps/Exchange/src/com/android/exchange/
H A DEasAccountService.java499 protected EasResponse sendPing(byte[] bytes, int heartbeat) throws IOException { argument
504 return sendHttpClientPost(EasSyncService.PING_COMMAND, new ByteArrayEntity(bytes),
/packages/apps/Exchange/tests/src/com/android/exchange/utility/
H A DCalendarUtilitiesTests.java124 byte[] bytes = new byte[] {0, 1, 2, 3, 4, 5, 6, 7};
127 assertEquals(0x0100, CalendarUtilities.getWord(bytes, 0));
128 assertEquals(0x03020100, CalendarUtilities.getLong(bytes, 0));
129 assertEquals(0x07060504, CalendarUtilities.getLong(bytes, 4));
132 CalendarUtilities.setWord(bytes, 0, 0xDEAD);
133 CalendarUtilities.setLong(bytes, 2, 0xBEEFBEEF);
134 CalendarUtilities.setWord(bytes, 6, 0xCEDE);
137 assertEquals(0xDEAD, CalendarUtilities.getWord(bytes, 0));
138 assertEquals(0xBEEFBEEF, CalendarUtilities.getLong(bytes, 2));
139 assertEquals(0xCEDE, CalendarUtilities.getWord(bytes,
781 parseIcsContent(byte[] bytes) argument
[all...]
/packages/apps/Mms/src/com/android/mms/util/
H A DThumbnailManager.java383 private Bitmap requestDecode(byte[] bytes, int offset, argument
389 BitmapFactory.decodeByteArray(bytes, offset, length, options));
/packages/apps/UnifiedEmail/src/org/apache/james/mime4j/codec/
H A DEncoderUtil.java336 byte[] bytes = encode(text, charset);
339 encoding = determineEncoding(bytes, usage);
343 return encodeB(prefix, text, usedCharacters, charset, bytes);
346 return encodeQ(prefix, text, usage, usedCharacters, charset, bytes);
354 * @param bytes
358 public static String encodeB(byte[] bytes) { argument
362 final int end = bytes.length;
364 int data = (bytes[idx] & 0xff) << 16 | (bytes[idx + 1] & 0xff) << 8
365 | bytes[id
401 encodeQ(byte[] bytes, Usage usage) argument
512 encodeB(String prefix, String text, int usedCharacters, Charset charset, byte[] bytes) argument
536 bEncodedLength(byte[] bytes) argument
540 encodeQ(String prefix, String text, Usage usage, int usedCharacters, Charset charset, byte[] bytes) argument
564 qEncodedLength(byte[] bytes, Usage usage) argument
608 determineEncoding(byte[] bytes, Usage usage) argument
[all...]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/utils/
H A DStringUtils.java381 public static String byteArrayToHexString(byte[] bytes) { argument
382 if (bytes == null || bytes.length == 0) {
386 for (byte b : bytes) {
405 final byte[] bytes = new byte[N / 2];
407 bytes[i / 2] = (byte) ((Character.digit(hexString.charAt(i), 16) << 4)
410 return bytes;
/packages/apps/Exchange/src/com/android/exchange/adapter/
H A DParser.java113 // The value read, as bytes
114 public byte[] bytes; field in class:Parser
229 return bytes;
349 * Initializes the parser with an input stream; reads the first 4 bytes (which are always the
488 bytes = new byte[length];
490 bytes[i] = (byte)readByte();

Completed in 441 milliseconds

12