Home
last modified time | relevance | path

Searched refs:baos (Results 1 – 25 of 39) sorted by relevance

12

/packages/modules/GeoTZ/s2storage/src/test/java/com/android/storage/table/packed/
DIntValuePackedTableTest.java46 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in valueSizeTooBig() local
48 PackedTableWriter writer = PackedTableWriter.create(baos, 5, 4, signedValue, null); in valueSizeTooBig()
51 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in valueSizeTooBig()
63 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in valueSizeMax_unsigned() local
65 try (PackedTableWriter writer = PackedTableWriter.create(baos, 5, 9, signedValue, null)) { in valueSizeMax_unsigned()
74 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in valueSizeMax_unsigned()
86 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in valueSizeMax_signed() local
88 try (PackedTableWriter writer = PackedTableWriter.create(baos, 5, 8, signedValue, null)) { in valueSizeMax_signed()
97 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in valueSizeMax_signed()
108 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in addEntry_outOfOrder() local
[all …]
DPackedTableReaderWriterTest.java79 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in headerFields() local
84 PackedTableWriter tableWriter = PackedTableWriter.create(baos, entrySizeBytes, keyBits, in headerFields()
88 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in headerFields()
100 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in entryGetValue_int() local
105 baos, entrySizeBytes, keyBits, signedValue, null); in entryGetValue_int()
111 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in entryGetValue_int()
119 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in entryGetValue_long() local
124 baos, entrySizeBytes, keyBits, signedValue, null); in entryGetValue_long()
136 BlockData blockData = new BlockData(createByteBuffer(baos.toByteArray())); in entryGetValue_long()
151 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in valueSizeMax_unsigned() local
[all …]
/packages/modules/RemoteKeyProvisioning/app/tests/unit/src/com/android/rkpdapp/unittest/
DUtils.java226 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in encodeAndSignSigStructure() local
227 new CborEncoder(baos).encode(new CborBuilder() in encodeAndSignSigStructure()
237 return signer.sign(baos.toByteArray()); in encodeAndSignSigStructure()
242 return ecdsaSigner.sign(baos.toByteArray()); in encodeAndSignSigStructure()
247 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in encodeEd25519PubKey() local
248 new CborEncoder(baos).encode(new CborBuilder() in encodeEd25519PubKey()
256 return baos.toByteArray(); in encodeEd25519PubKey()
261 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in encodeP256PubKey() local
278 new CborEncoder(baos).encode(coseKey); in encodeP256PubKey()
279 return baos.toByteArray(); in encodeP256PubKey()
[all …]
DSystemInterfaceTest.java312 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in generateEekChain() local
313 new CborEncoder(baos).encode(new CborBuilder() in generateEekChain()
321 return baos.toByteArray(); in generateEekChain()
350 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in generateEekChain() local
351 new CborEncoder(baos).encode(new CborBuilder() in generateEekChain()
359 return baos.toByteArray(); in generateEekChain()
/packages/modules/GeoTZ/s2storage/src/test/java/com/android/storage/block/read/
DBlockDataTest.java37 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in getSize() local
38 TypedOutputStream typedOutputStream = new TypedOutputStream(baos); in getSize()
45 byte[] blockDataBytes = baos.toByteArray(); in getSize()
53 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in getByteBuffer() local
54 TypedOutputStream typedOutputStream = new TypedOutputStream(baos); in getByteBuffer()
61 byte[] blockDataBytes = baos.toByteArray(); in getByteBuffer()
74 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in typedRandomAccess() local
75 TypedOutputStream typedOutputStream = new TypedOutputStream(baos); in typedRandomAccess()
91 byte[] blockDataBytes = baos.toByteArray(); in typedRandomAccess()
/packages/modules/GeoTZ/s2storage/src/test/java/com/android/storage/io/
DTypedStreamsTest.java40 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in writeReadOk() local
41 TypedOutputStream tos = new TypedOutputStream(baos); in writeReadOk()
77 byte[] bytes = baos.toByteArray(); in writeReadOk()
142 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in writeVarByteValueUnusedBitsCheck() local
143 TypedOutputStream tos = new TypedOutputStream(baos); in writeVarByteValueUnusedBitsCheck()
184 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in writeBoundChecks() local
185 TypedOutputStream tos = new TypedOutputStream(baos); in writeBoundChecks()
201 assertEquals(0, baos.toByteArray().length); in writeBoundChecks()
/packages/modules/RemoteKeyProvisioning/app/src/com/android/rkpdapp/utils/
DCborUtils.java248 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in parseGeekResponse() local
249 new CborEncoder(baos).encode(curveAndEekChain.get(EEK_CERT_CHAIN_INDEX)); in parseGeekResponse()
251 resp.addGeek(curve.getValue().intValue(), baos.toByteArray()); in parseGeekResponse()
277 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in buildProvisioningInfo() local
278 new CborEncoder(baos).encode(new CborBuilder() in buildProvisioningInfo()
285 return baos.toByteArray(); in buildProvisioningInfo()
317 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in buildCertificateRequest() local
318 new CborEncoder(baos).encode(new CborBuilder() in buildCertificateRequest()
329 return baos.toByteArray(); in buildCertificateRequest()
416 final ByteArrayOutputStream baos = new ByteArrayOutputStream(); in encodeCbor() local
[all …]
/packages/services/Telephony/utils/satellite/s2storage/src/write/java/com/android/telephony/sats2range/write/
DSuffixTableSharedDataWriter.java36 try (ByteArrayOutputStream baos = new ByteArrayOutputStream(); in toBytes() argument
37 TypedOutputStream tos = new TypedOutputStream(baos)) { in toBytes()
40 return baos.toByteArray(); in toBytes()
DSuffixTableWriter.java194 ByteArrayOutputStream baos = new ByteArrayOutputStream();
195 try (TypedOutputStream tos = new TypedOutputStream(baos)) {
200 return baos.toByteArray();
/packages/modules/GeoTZ/tzs2storage/src/write/java/com/android/timezone/location/storage/tzs2range/write/
DSuffixTableSharedDataWriter.java36 try (ByteArrayOutputStream baos = new ByteArrayOutputStream(); in toBytes() argument
37 TypedOutputStream tos = new TypedOutputStream(baos)) { in toBytes()
41 return baos.toByteArray(); in toBytes()
DSuffixTableWriter.java201 ByteArrayOutputStream baos = new ByteArrayOutputStream();
202 try (TypedOutputStream tos = new TypedOutputStream(baos)) {
207 return baos.toByteArray();
/packages/providers/ContactsProvider/src/com/android/providers/contacts/
DPhotoProcessor.java246 final ByteArrayOutputStream baos = new ByteArrayOutputStream(); in getCompressedBytes() local
247 final boolean compressed = b.compress(Bitmap.CompressFormat.JPEG, quality, baos); in getCompressedBytes()
248 baos.flush(); in getCompressedBytes()
249 baos.close(); in getCompressedBytes()
250 byte[] result = baos.toByteArray(); in getCompressedBytes()
/packages/modules/AdServices/shared/tests/side-less/java/com/android/adservices/shared/testing/
DStandardStreamsLoggerTest.java44 try (ByteArrayOutputStream baos = new ByteArrayOutputStream()) { in testLogWithThrowable() argument
45 t.printStackTrace(new PrintStream(baos)); in testLogWithThrowable()
46 stackTrace = baos.toString(); in testLogWithThrowable()
/packages/providers/UserDictionaryProvider/src/com/android/providers/userdictionary/
DDictionaryBackupAgent.java161 ByteArrayOutputStream baos = new ByteArrayOutputStream(cursor.getCount() * 10); in getDictionary() local
164 gzip = new GZIPOutputStream(baos); in getDictionary()
189 return baos.toByteArray(); in getDictionary()
199 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in restoreDictionary() local
203 baos.write(tempData, 0, got); in restoreDictionary()
206 dictionary = baos.toByteArray(); in restoreDictionary()
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/mapclient/obex/
DRequestGetMessage.java66 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in readResponse() local
72 baos.write(buf, 0, len); in readResponse()
83 bmsg = baos.toString(StandardCharsets.UTF_8.name()); in readResponse()
/packages/apps/CertInstaller/src/com/android/certinstaller/
DUtil.java34 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in toBytes() local
36 ObjectOutputStream os = new ObjectOutputStream(baos); in toBytes()
42 return baos.toByteArray(); in toBytes()
/packages/modules/OnDevicePersonalization/framework/java/com/android/ondevicepersonalization/internal/util/
DByteArrayParceledListSlice.java83 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in create() local
85 ObjectOutputStream oos = new ObjectOutputStream(baos); in create()
87 byteArrayList.add(baos.toByteArray()); in create()
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/asset/
DResourceAssetLoader.java92 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in loadData() local
93 bitmap.compress(Bitmap.CompressFormat.PNG, 100, baos); in loadData()
94 callback.onDataReady(new ByteArrayInputStream(baos.toByteArray())); in loadData()
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/
DEvenMoreAsserts.java69 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in assertImageRawData() local
74 baos.write(buffer, 0, count); in assertImageRawData()
78 assertImageRawData(context, expected, baos.toByteArray()); in assertImageRawData()
/packages/apps/Car/systemlibs/car-qc-lib/tests/unit/src/com/android/car/qc/testutils/
DTestQCProvider.java82 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in onBind() local
83 bitmap.compress(Bitmap.CompressFormat.PNG, 100, baos); in onBind()
84 byte[] b = baos.toByteArray(); in onBind()
/packages/apps/Dialer/java/com/android/incallui/calllocation/impl/
DHttpFetcher.java83 final ByteArrayOutputStream baos = new ByteArrayOutputStream(); in sendRequestAsByteArray() local
88 baos.write(buffer, 0, bytesRead); in sendRequestAsByteArray()
92 handleBadResponse(url.toString(), baos.toByteArray()); in sendRequestAsByteArray()
99 byte[] response = baos.toByteArray(); in sendRequestAsByteArray()
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/
DSoftApBackupRestoreTest.java132 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in getBytesForBackup() local
133 DataOutputStream out = new DataOutputStream(baos); in getBytesForBackup()
142 return baos.toByteArray(); in getBytesForBackup()
412 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in retrieveSpecificVersionBackupDataFromSoftApConfiguration() local
413 DataOutputStream out = new DataOutputStream(baos); in retrieveSpecificVersionBackupDataFromSoftApConfiguration()
456 return baos.toByteArray(); in retrieveSpecificVersionBackupDataFromSoftApConfiguration()
/packages/modules/Wifi/service/java/com/android/server/wifi/
DSoftApBackupRestore.java97 final ByteArrayOutputStream baos = new ByteArrayOutputStream(); in retrieveBackupDataFromSoftApConfiguration() local
98 final DataOutputStream out = new DataOutputStream(baos); in retrieveBackupDataFromSoftApConfiguration()
102 xmlOut.setOutput(baos, StandardCharsets.UTF_8.name()); in retrieveBackupDataFromSoftApConfiguration()
142 return baos.toByteArray(); in retrieveBackupDataFromSoftApConfiguration()
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
DBitmapUtils.java242 ByteArrayOutputStream baos = new ByteArrayOutputStream(65536); in compressToBytes() local
243 bitmap.compress(CompressFormat.JPEG, quality, baos); in compressToBytes()
244 return baos.toByteArray(); in compressToBytes()
/packages/providers/CallLogProvider/src/com/android/calllogbackup/
DCallLogBackupAgent.java649 ByteArrayOutputStream baos = new ByteArrayOutputStream(); in addCallToBackup() local
650 DataOutputStream data = new DataOutputStream(baos); in addCallToBackup()
698 output.writeEntityHeader(Integer.toString(call.id), baos.size()); in addCallToBackup()
699 output.writeEntityData(baos.toByteArray(), baos.size()); in addCallToBackup()
704 Log.d(TAG, "Wrote call to backup: " + call + " with byte array: " + baos); in addCallToBackup()

12