Home
last modified time | relevance | path

Searched refs:utf8Bytes (Results 1 – 4 of 4) sorted by relevance

/aosp12/packages/apps/Bluetooth/src/com/android/bluetooth/map/
H A DBluetoothMapUtils.java420 byte[] utf8Bytes = new byte[utf8String.length() + 1]; in truncateUtf8StringToBytearray()
422 System.arraycopy(utf8String.getBytes("UTF-8"), 0, utf8Bytes, 0, utf8String.length()); in truncateUtf8StringToBytearray()
428 if (utf8Bytes.length > maxLength) { in truncateUtf8StringToBytearray()
431 if ((utf8Bytes[maxLength - 1] & 0xC0) == 0x80) { in truncateUtf8StringToBytearray()
433 if ((utf8Bytes[i] & 0xC0) == 0xC0) { in truncateUtf8StringToBytearray()
436 utf8Bytes = Arrays.copyOf(utf8Bytes, i + 1); in truncateUtf8StringToBytearray()
437 utf8Bytes[i] = 0; in truncateUtf8StringToBytearray()
443 utf8Bytes = Arrays.copyOf(utf8Bytes, maxLength); in truncateUtf8StringToBytearray()
444 utf8Bytes[maxLength - 1] = 0; in truncateUtf8StringToBytearray()
447 return utf8Bytes; in truncateUtf8StringToBytearray()
/aosp12/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/recoverablekeystore/
H A DKeySyncUtilsTest.java62 utf8Bytes("g09TEvo6XqVdNaYdRggzn5w2C5rCeE1F");
64 utf8Bytes("snQzsbvclkSsG6PwasAp1oFLzbq3KtFe");
75 byte[] lockScreenHash = utf8Bytes("012345678910"); in calculateThmKfHash_isShaOfLockScreenHashWithPrefix()
79 assertArrayEquals(calculateSha256(utf8Bytes("THM_KF_hash012345678910")), thmKfHash); in calculateThmKfHash_isShaOfLockScreenHashWithPrefix()
84 byte[] thmKfHash = KeySyncUtils.calculateThmKfHash(utf8Bytes("1234")); in calculateThmKfHash_is256BitsLong()
122 utf8Bytes("hello, world!"), in concat_concatenatesArrays()
124 utf8Bytes("hello"), in concat_concatenatesArrays()
125 utf8Bytes(", "), in concat_concatenatesArrays()
126 utf8Bytes("world"), in concat_concatenatesArrays()
127 utf8Bytes("!"))); in concat_concatenatesArrays()
[all …]
H A DKeySyncTaskTest.java199 KeySyncTask.hashCredentialsBySaltedSha256(utf8Bytes("123"), in hashCredentialsBySaltedSha256_returnsDifferentHashEvenIfConcatIsSame()
201 KeySyncTask.hashCredentialsBySaltedSha256(utf8Bytes("1234"), in hashCredentialsBySaltedSha256_returnsDifferentHashEvenIfConcatIsSame()
862 private static byte[] utf8Bytes(String s) { in utf8Bytes() method in KeySyncTaskTest
/aosp12/art/dexdump/
H A Ddexdump.cc392 static size_t utf8Bytes(char start_byte) { in utf8Bytes() function
435 } else if (utf8Bytes(uc) == 2) { in dumpXmlAttribute()
439 } else if (utf8Bytes(uc) == 3) { in dumpXmlAttribute()
445 CHECK_EQ(utf8Bytes(uc), 4u); in dumpXmlAttribute()