/cts/tests/tests/time/shell_utils/common/android/app/time/cts/shell/ |
D | DeviceShellCommandExecutor.java | 29 byte[] bytes = executeToBytesInternal(command); in executeToString() 30 String result = parseBytesAsString(bytes); in executeToString() 38 byte[] bytes = executeToBytesInternal(command); in executeToTrimmedString() 39 String result = parseBytesAsString(bytes).trim(); in executeToTrimmedString() 50 byte[] bytes = executeToBytesInternal(command); in executeToBoolean() 51 boolean result = parseBytesAsBoolean(bytes); in executeToBoolean() 59 byte[] bytes = executeToBytesInternal(command); in executeToBytes() 60 log("Executed '" + command + "': Result='" + Arrays.toString(bytes) + "'"); in executeToBytes() 61 return bytes; in executeToBytes()
|
/cts/tests/tests/os/src/android/os/storage/cts/ |
D | StorageManagerTest.java | 398 final byte[] bytes; field in StorageManagerTest.TestProxyFileDescriptorCallback 408 bytes = new byte[size]; in TestProxyFileDescriptorCallback() 410 bytes[i] = seedBytes[i % seedBytes.length]; in TestProxyFileDescriptorCallback() 420 bytes[(int)(i + offset)] = data[i]; in onWrite() 430 final int len = (int)(Math.min(size, bytes.length - offset)); in onRead() 432 data[i] = bytes[(int)(i + offset)]; in onRead() 442 return bytes.length; in onGetSize() 477 final byte[] bytes = new byte[100]; in testOpenProxyFileDescriptor() 481 Os.read(appleFd.getFileDescriptor(), bytes, 0, 100); in testOpenProxyFileDescriptor() local 483 assertEquals(appleCallback.bytes[i * 100 + j], bytes[j]); in testOpenProxyFileDescriptor() [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/hcef/ |
D | MyHostFelicaService.java | 62 public byte[] processNfcFPacket(byte[] bytes, Bundle bundle) { in processNfcFPacket() argument 64 if (bytes.length < 2 + NFCID2.length) { in processNfcFPacket() 69 if (bytes[2 + i] != NFCID2[i]) { in processNfcFPacket() 74 byte cmd = bytes[1]; in processNfcFPacket() 76 return handleSystemCodeRequest(bytes); in processNfcFPacket() 78 return handleEchoRequest(bytes); in processNfcFPacket() 84 return bytes; in processNfcFPacket()
|
/cts/hostsidetests/securitybulletin/securityPatch/CVE-2019-1988/ |
D | poc.cpp | 30 int decode(sk_sp<SkData> bytes, uint8_t sampleSize) { in decode() argument 31 auto codec = SkAndroidCodec::MakeFromData(bytes); in decode() 70 auto bytes = SkData::MakeWithoutCopy(data, size); in main() local 71 bytes = SkData::MakeSubset(bytes.get(), 1, size - 1); in main() 73 int ret = decode(bytes, SAMPLE_SIZE); in main()
|
/cts/tests/tests/carrierapi/src/android/carrierapi/cts/ |
D | IccUtils.java | 30 public static String bytesToHexString(byte[] bytes) { in bytesToHexString() argument 31 StringBuilder ret = new StringBuilder(2 * bytes.length); in bytesToHexString() 32 for (int i = 0; i < bytes.length; i++) { in bytesToHexString() 34 b = 0x0f & (bytes[i] >> 4); in bytesToHexString() 36 b = 0x0f & bytes[i]; in bytesToHexString()
|
/cts/tests/tests/keystore/src/android/keystore/cts/ |
D | CountingSecureRandom.java | 52 public synchronized void nextBytes(byte[] bytes) { in nextBytes() argument 53 if ((bytes != null) && (bytes.length > 0)) { in nextBytes() 54 mOutputSizeBytes.addAndGet(bytes.length); in nextBytes() 56 mDelegate.nextBytes(bytes); in nextBytes()
|
/cts/tools/cfassembler/src/dxconvext/ |
D | ClassFileAssembler.java | 128 private void calcSignature(byte[] bytes) { in calcSignature() argument 137 md.update(bytes, 32, bytes.length - 32); in calcSignature() 140 int amt = md.digest(bytes, 12, 20); in calcSignature() 158 private void calcChecksum(byte[] bytes) { in calcChecksum() argument 161 a32.update(bytes, 12, bytes.length - 12); in calcChecksum() 165 bytes[8] = (byte) sum; in calcChecksum() 166 bytes[9] = (byte) (sum >> 8); in calcChecksum() 167 bytes[10] = (byte) (sum >> 16); in calcChecksum() 168 bytes[11] = (byte) (sum >> 24); in calcChecksum()
|
D | ClassFileParser.java | 79 byte[] bytes = FileUtils.readFile(inFile); in process() 91 ClassFileParser.this.processFileBytes(w, cfName, bytes); in process() 132 public void startParsingMember(ByteArray bytes, int offset, in processFileBytes() 136 + offset + ", len:" + (bytes.size() - offset) in processFileBytes() 152 public void endParsingMember(ByteArray bytes, int offset, in processFileBytes() 154 ByteArray ba = bytes.slice(offset, bytes.size()); in processFileBytes() 170 public void parsed(ByteArray bytes, int offset, int len, in processFileBytes() 176 ByteArray ba = bytes.slice(offset, offset + len); in processFileBytes()
|
/cts/tests/location/location_gnss/src/android/location/cts/gnss/asn1/base/ |
D | PacketBuilder.java | 29 byte[] bytes = appendix.getPaddedBytes(); in append() 31 bitStream.appendByte(bytes[i]); in append() 34 byte highBits = bytes[bytes.length - 1]; in append()
|
D | PerAlignedUtils.java | 162 byte[] bytes, int minimumLength, int maximumLength) { in encodeConstrainedLengthOfBytes() argument 164 return encodeSemiConstrainedLengthOfBytes(bytes); in encodeConstrainedLengthOfBytes() 168 bytes.length, minimumLength, maximumLength); in encodeConstrainedLengthOfBytes() 169 if (bytes.length == 0) { in encodeConstrainedLengthOfBytes() 174 for (byte aByte : bytes) { in encodeConstrainedLengthOfBytes() 208 byte[] bytes) { in encodeSemiConstrainedLengthOfBytes() argument 209 int n = bytes.length; in encodeSemiConstrainedLengthOfBytes() 213 for (byte b : bytes) { in encodeSemiConstrainedLengthOfBytes() 225 byte[] bytes) { in encodeUnconstrainedLengthOfBytes() argument 228 return encodeSemiConstrainedLengthOfBytes(bytes); in encodeUnconstrainedLengthOfBytes()
|
D | Asn1Utf8String.java | 58 private void setValueBytes(byte[] bytes) { in setValueBytes() argument 59 value = new String(bytes, StandardCharsets.UTF_8); in setValueBytes() 89 byte[] bytes = getValueBytes(); in encodePerImpl() 91 return PerAlignedUtils.encodeSemiConstrainedLengthOfBytes(bytes); in encodePerImpl() 93 return PerUnalignedUtils.encodeSemiConstrainedLengthOfBytes(bytes); in encodePerImpl()
|
D | PerUnalignedUtils.java | 123 byte[] bytes, int minimumLength, int maximumLength) { in encodeConstrainedLengthOfBytes() argument 125 return encodeSemiConstrainedLengthOfBytes(bytes); in encodeConstrainedLengthOfBytes() 129 bytes.length, minimumLength, maximumLength); in encodeConstrainedLengthOfBytes() 130 if (bytes.length == 0) { in encodeConstrainedLengthOfBytes() 134 for (byte aByte : bytes) { in encodeConstrainedLengthOfBytes() 166 byte[] bytes) { in encodeSemiConstrainedLengthOfBytes() argument 167 int n = bytes.length; in encodeSemiConstrainedLengthOfBytes() 170 for (byte b : bytes) { in encodeSemiConstrainedLengthOfBytes()
|
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/ |
D | UiccUtil.java | 144 public static String bytesToHexString(@Nullable byte[] bytes) { in bytesToHexString() argument 145 if (bytes == null) return null; in bytesToHexString() 147 StringBuilder ret = new StringBuilder(2 * bytes.length); in bytesToHexString() 149 for (int i = 0; i < bytes.length; i++) { in bytesToHexString() 151 b = 0x0f & (bytes[i] >> 4); in bytesToHexString() 153 b = 0x0f & bytes[i]; in bytesToHexString()
|
/cts/common/device-side/bedstead/queryable/src/main/java/com/android/queryable/util/ |
D | SerializableParcelWrapper.java | 69 byte[] bytes = new byte[size]; in readObject() 70 inputStream.read(bytes); in readObject() 72 p.unmarshall(bytes, 0, size); in readObject() 82 byte[] bytes = p.marshall(); in writeObject() 85 outputStream.writeInt(bytes.length); in writeObject() 86 outputStream.write(bytes); in writeObject()
|
/cts/tools/utils/ |
D | monsoon.py | 155 bytes = self._ReadPacket() 156 if not bytes: return None 157 if len(bytes) != struct.calcsize(STATUS_FORMAT) or bytes[0] != "\x10": 159 ord(bytes[0]), len(bytes)) 162 status = dict(zip(STATUS_FIELDS, struct.unpack(STATUS_FORMAT, bytes))) 224 bytes = self._ReadPacket() 225 if not bytes: return None 226 if len(bytes) < 4 + 8 + 1 or bytes[0] < "\x20" or bytes[0] > "\x2F": 228 ord(bytes[0]), len(bytes)) 231 seq, type, x, y = struct.unpack("BBBB", bytes[:4]) [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/tech/ |
D | NfcUtils.java | 49 static CharSequence displayByteArray(byte[] bytes) { in displayByteArray() argument 51 for (int i = 0; i < bytes.length; i++) { in displayByteArray() 52 builder.append(Byte.toString(bytes[i])); in displayByteArray() 53 if (i + 1 < bytes.length) { in displayByteArray()
|
/cts/apps/CtsVerifier/assets/scripts/power_monitors/ |
D | monsoon.py | 261 bytes = self._ReadPacket() 262 if not bytes: return None 263 if len(bytes) != struct.calcsize(STATUS_FORMAT) or bytes[0] != "\x10": 265 ord(bytes[0]), len(bytes))) 268 status = dict(zip(STATUS_FIELDS, struct.unpack(STATUS_FORMAT, bytes))) 338 bytes = self._ReadPacket(verbose) 340 if not bytes: return None 341 if len(bytes) < 4 + 8 + 1 or bytes[0] < "\x20" or bytes[0] > "\x2F": 343 ord(bytes[0]), len(bytes)), debug=verbose) 346 seq, type, x, y = struct.unpack("BBBB", bytes[:4]) [all …]
|
/cts/tests/tests/media/misc/jni/ |
D | native-media-jni.cpp | 76 void *bytes; in Java_android_media_misc_cts_NativeDecoderTest_testFormatNative() local 78 if(!AMediaFormat_getBuffer(format, "csd-0", &bytes, &bytesize) in Java_android_media_misc_cts_NativeDecoderTest_testFormatNative() 79 || bytesize != sizeof(foo) || *((uint32_t*)bytes) != 0xdeadbeef) { in Java_android_media_misc_cts_NativeDecoderTest_testFormatNative() 145 uint8_t bytes[16]; in Java_android_media_misc_cts_NativeDecoderTest_testCryptoInfoNative() local 146 AMediaCodecCryptoInfo_getKey(ci, bytes); in Java_android_media_misc_cts_NativeDecoderTest_testCryptoInfoNative() 147 if (memcmp(key, bytes, 16) != 0) { in Java_android_media_misc_cts_NativeDecoderTest_testCryptoInfoNative() 151 AMediaCodecCryptoInfo_getIV(ci, bytes); in Java_android_media_misc_cts_NativeDecoderTest_testCryptoInfoNative() 152 if (memcmp(iv, bytes, 16) != 0) { in Java_android_media_misc_cts_NativeDecoderTest_testCryptoInfoNative()
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/wifiaware/ |
D | BaseTestCase.java | 162 public static String bytesToHex(byte[] bytes, Character separator) { in bytesToHex() argument 169 char[] hexChars = new char[bytes.length * 2 + (useSeparator ? bytes.length - 1 : 0)]; in bytesToHex() 171 for (int j = 0; j < bytes.length; j++) { in bytesToHex() 175 int v = bytes[j] & 0xFF; in bytesToHex()
|
/cts/tests/tests/media/audio/jni/ |
D | audio-metadata-native.cpp | 55 const uint8_t* bytes = in Java_android_media_audio_cts_AudioMetadataTest_nativeGetByteBuffer() local 57 if (bytes == nullptr) { in Java_android_media_audio_cts_AudioMetadataTest_nativeGetByteBuffer() 62 audio_utils::metadata::ByteString(bytes, sizeInBytes)); in Java_android_media_audio_cts_AudioMetadataTest_nativeGetByteBuffer()
|
/cts/hostsidetests/backup/FullBackupOnly/src/ |
D | FullBackupOnlyBackupAgent.java | 104 byte[] bytes = new byte[size]; in readFileToBytes() 107 buf.read(bytes, 0, bytes.length); in readFileToBytes() 114 return bytes; in readFileToBytes()
|
D | FullBackupOnlyTest.java | 140 byte[] bytes = new byte[FILE_SIZE_BYTES]; in addData() 141 new Random().nextBytes(bytes); in addData() 144 bos.write(bytes, 0, bytes.length); in addData()
|
/cts/hostsidetests/backup/BackupEligibility/src/ |
D | BackupEligibilityTest.java | 119 byte[] bytes = new byte[FILE_SIZE_BYTES]; in addData() 120 new Random().nextBytes(bytes); in addData() 123 bos.write(bytes, 0, bytes.length); in addData()
|
/cts/tests/backup/app/src/android/backup/app/ |
D | MainActivity.java | 67 byte[] bytes = new byte[DATA_CHUNK_SIZE]; in createFile() 68 new Random().nextBytes(bytes); in createFile() 74 bos.write(bytes, 0, bytesToWrite); in createFile()
|
/cts/hostsidetests/packagemanager/dynamicmime/test/src/android/dynamicmime/testapp/util/ |
D | Utils.java | 69 ByteArrayOutputStream bytes = new ByteArrayOutputStream(); in readFully() local 76 bytes.write(buffer, 0, count); in readFully() 81 return new String(bytes.toByteArray()); in readFully()
|