Home
last modified time | relevance | path

Searched refs:wrap (Results 1 – 25 of 52) sorted by relevance

123

/tools/apksig/src/test/java/com/android/apksig/internal/util/
DChainedDataSourceTest.java42 DataSources.asDataSource(ByteBuffer.wrap("12".getBytes(US_ASCII))), in setUp()
43 DataSources.asDataSource(ByteBuffer.wrap("34567".getBytes(US_ASCII))), in setUp()
44 DataSources.asDataSource(ByteBuffer.wrap("".getBytes(US_ASCII))), in setUp()
45 DataSources.asDataSource(ByteBuffer.wrap("890".getBytes(US_ASCII))), in setUp()
46 DataSources.asDataSource(ByteBuffer.wrap("".getBytes(US_ASCII)))); in setUp()
57 ByteBuffer.wrap("1234567890".substring(begin, end).getBytes(US_ASCII)), in feedAllPossibleRanges()
74 ByteBuffer.wrap("1234567890".substring(begin, end).getBytes(US_ASCII)), in getByteBufferFromAllPossibleRanges()
96 ByteBuffer.wrap("1234567890".substring(begin, end).getBytes(US_ASCII)), in copyTo()
110 ByteBuffer.wrap("1234567890".substring(begin, end).getBytes(US_ASCII)), in slice()
DVerityTreeBuilderTest.java72 DataSources.asDataSource(ByteBuffer.wrap(input)))); in generateRootHash()
80 return DataSources.asDataSource(ByteBuffer.wrap(data.getBytes(UTF_8))); in makeStringDataSource()
96 DataSources.asDataSource(ByteBuffer.wrap(sampleEoCDFromDisk))); in generateVerityTreeRootHashFromDummyDataSource()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zip/utils/
DLittleEndianUtilsTest.java29 assertEquals(0x0102, LittleEndianUtils.readUnsigned2Le(ByteBuffer.wrap( in read2Le()
31 assertEquals(0xfedc, LittleEndianUtils.readUnsigned2Le(ByteBuffer.wrap( in read2Le()
63 ByteBuffer in = ByteBuffer.wrap(out.array()); in readWrite2Le()
71 assertEquals(0x01020304, LittleEndianUtils.readUnsigned4Le(ByteBuffer.wrap( in read4Le()
73 assertEquals(0xfedcba98L, LittleEndianUtils.readUnsigned4Le(ByteBuffer.wrap( in read4Le()
106 ByteBuffer in = ByteBuffer.wrap(out.array()); in readWrite4Le()
/tools/apksig/src/test/java/com/android/apksig/internal/asn1/
DAsn1BerParserTest.java47 ByteBuffer input = ByteBuffer.wrap(HexEncoding.decode("300012345678")); in testEmptySequence()
247 ByteBuffer input = ByteBuffer.wrap(HexEncoding.decode("0280020401000002010c")); in testPrimitiveIndefiniteLengthEncodingWithGarbage()
256 input = ByteBuffer.wrap(HexEncoding.decode("0280028001000002010c")); in testPrimitiveIndefiniteLengthEncodingWithGarbage()
270 ByteBuffer input = ByteBuffer.wrap(HexEncoding.decode("308002020000000002010c")); in testConstructedIndefiniteLengthEncodingWithoutNestedIndefiniteLengthDataValues()
286 ByteBuffer.wrap(HexEncoding.decode("308002800300000280030000020103000002010c")); in testConstructedIndefiniteLengthEncodingWithNestedIndefiniteLengthDataValues()
299 ByteBuffer input = ByteBuffer.wrap(HexEncoding.decode("3080308002040000000002010c")); in testConstructedIndefiniteLengthEncodingWithGarbage()
307 ? null : ByteBuffer.wrap(HexEncoding.decode(hexEncodedInput)); in parse()
DAsn1DerEncoderTest.java53 ByteBuffer.wrap(new byte[] {1, 2, 3})))); in testOctetString()
58 ByteBuffer.wrap(new byte[] {(byte) 0xff})))); in testOctetString()
63 new SequenceWithByteBufferOctetString(ByteBuffer.wrap(new byte[0])))); in testOctetString()
72 ByteBuffer.wrap(new byte[] {1, 2, 3})))); in testBitString()
77 ByteBuffer.wrap(new byte[] {(byte) 0xff})))); in testBitString()
82 new SequenceWithByteBufferBitString(ByteBuffer.wrap(new byte[0])))); in testBitString()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zip/
DExtraFieldTest.java134 segments.get(0).write(ByteBuffer.wrap(segData)); in readSingleExtraField()
182 segments.get(0).write(ByteBuffer.wrap(segData)); in readMultipleExtraFields()
187 segments.get(1).write(ByteBuffer.wrap(segData)); in readMultipleExtraFields()
192 segments.get(2).write(ByteBuffer.wrap(segData)); in readMultipleExtraFields()
234 s.write(ByteBuffer.wrap(sData)); in addExtraFieldToExistingEntry()
330 s.write(ByteBuffer.wrap(sData)); in updateExtraFieldOfExistingEntry()
/tools/apksig/src/test/java/com/android/apksig/internal/asn1/ber/
DBerDataValueTest.java37 ByteBuffer.wrap(HexEncoding.decode("aa")),
38 ByteBuffer.wrap(HexEncoding.decode("bb")),
45 ByteBuffer.wrap(HexEncoding.decode("cc")),
46 ByteBuffer.wrap(HexEncoding.decode("dd")),
114 ByteBuffer.wrap(HexEncoding.decode("300203040500")), in testContentsReader()
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/zip/
DZFile.java755 ByteBuffer.wrap(last, foundEocdSignature, last.length - foundEocdSignature); in readEocd()
801 if (LittleEndianUtils.readUnsigned4Le(ByteBuffer.wrap(possibleZip64Locator)) == in readEocd()
860 ByteBuffer.wrap(directoryData), in readCentralDirectory()
2340 return directRead(offset, ByteBuffer.wrap(data, start, count)); in directRead()
2392 directFullyRead(offset, ByteBuffer.wrap(data)); in directFullyRead()
2614 ByteBuffer bytes = ByteBuffer.wrap(comment, i, comment.length - i); in setEocdComment()
DStoredEntry.java438 ByteBuffer bytes = ByteBuffer.wrap(localHeader); in readLocalHeader()
507 ByteBuffer ddBytes = ByteBuffer.wrap(ddData); in readDataDescriptorRecord()
651 ByteSource.wrap(rawContents), rawContents.length)); in loadSourceIntoMemory()
DEncodeUtils.java86 .decode(ByteBuffer.wrap(data)) in decode()
94 return charset.decode(ByteBuffer.wrap(data)).toString(); in decode()
DExtraField.java147 ByteBuffer buffer = ByteBuffer.wrap(rawData); in parseSegments()
379 ByteBuffer dataBuffer = ByteBuffer.wrap(data); in AlignmentSegment()
/tools/apksig/src/main/java/com/android/apksig/internal/util/
DX509CertificateUtils.java124 ByteBuffer.wrap(encodedForm)); in generateCertificate()
186 ByteBuffer encodedCertsBuffer = ByteBuffer.wrap(encodedCerts); in generateCertificates()
276 return ByteBuffer.wrap(derEncoding); in getNextDEREncodedCertificateBlock()
DByteArrayDataSink.java120 return ByteBuffer.wrap(mArray, (int) offset, size).slice(); in getByteBuffer()
198 return ByteBuffer.wrap(mArray, (int) (mSliceOffset + offset), size).slice(); in getByteBuffer()
/tools/metalava/src/main/java/com/android/tools/metalava/
DExtractAnnotations.kt338 val annotation = JavaUAnnotation.wrap(psiAnnotation) in <lambda>()
484 JavaUAnnotation.wrap(annotationItem.psiAnnotation) in <lambda>()
550 val annotation = JavaUAnnotation.wrap(memberValue) in <lambda>()
DOptions.kt26 import com.android.utils.SdkUtils.wrap in <lambda>()
2186 out.println(wrap(HELP_PROLOGUE, MAX_LINE_WIDTH, "")) in <lambda>()
2512 wrap( in <lambda>()
2517 wrap( in <lambda>()
/tools/apksig/src/test/java/com/android/apksig/
DApkSignerTest.java337 ByteBuffer.wrap(Resources.toByteArray(ApkSigner.class, inResourceName))); in signGolden()
917 ByteBuffer.wrap(Resources.toByteArray(getClass(), expectedOutResourceName)); in assertGolden()
957 ByteBuffer.wrap(Resources.toByteArray(getClass(), inResourceName))); in sign()
/tools/apksig/src/main/java/com/android/apksig/
DApkSigner.java453 ZipUtils.deflate(ByteBuffer.wrap(uncompressedData)); in sign()
495 ZipUtils.deflate(ByteBuffer.wrap(uncompressedData)); in sign()
813 return ByteBuffer.wrap( in getAndroidManifestFromApk()
DSigningCertificateLineage.java158 V3SigningCertificateLineage.readSigningCertificateLineage(ByteBuffer.wrap( in readFromV3AttributeValue()
355 ByteBuffer prefixedSignedData = ByteBuffer.wrap( in spawnDescendant()
/tools/apksig/src/test/java/com/android/apksig/util/
DDataSourceFromByteBufferTest.java34 ByteBuffer buf = ByteBuffer.wrap("abcdefgh".getBytes(StandardCharsets.UTF_8)); in testChangesToBufferPosAndLimitNotVisible()
48 return CloseableWithDataSource.of(DataSources.asDataSource(ByteBuffer.wrap(contents))); in createDataSource()
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/zip/utils/
DByteTracker.java51 return new CloseableDelegateByteSource(ByteSource.wrap(data), data.length) { in fromStream()
71 return new CloseableDelegateByteSource(ByteSource.wrap(data), data.length) {
/tools/apksig/src/test/java/com/android/apksig/internal/apk/
DApkSigningBlockUtilsTest.java64 DataSources.asDataSource(ByteBuffer.wrap(part2)), in setUp()
65 DataSources.asDataSource(ByteBuffer.wrap(part3)), in setUp()
/tools/apksig/src/main/java/com/android/apksig/internal/asn1/ber/
DInputStreamBerDataValueReader.java90 ByteBuffer.wrap(encoded, contentsOffsetInDataValue, contentsLength); in readDataValue()
92 ByteBuffer.wrap(encoded), in readDataValue()
/tools/apksig/src/apksigner/java/com/android/apksigner/
DPasswordRetriever.java280 .encode(CharBuffer.wrap(pwd)); in encodePassword()
291 .decode(ByteBuffer.wrap(pwdBytes)); in decodePassword()
/tools/external/fat32lib/src/main/java/de/waldheinz/fs/fat/
DFat.java179 device.read(offset, ByteBuffer.wrap(data)); in read()
202 device.write(offset, ByteBuffer.wrap(data)); in writeCopy()
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/sign/
DSigningExtension.java350 DataSource centralDir = DataSources.asDataSource(ByteBuffer.wrap(centralDirBytes)); in onOutputZipEntriesWritten()
351 DataSource eocd = DataSources.asDataSource(ByteBuffer.wrap(eocdBytes)); in onOutputZipEntriesWritten()

123