Home
last modified time | relevance | path

Searched refs:raf (Results 1 – 12 of 12) sorted by relevance

/frameworks/multidex/library/src/androidx/multidex/
DZipUtil.java55 RandomAccessFile raf = new RandomAccessFile(apk, "r"); in getZipCrc() local
57 CentralDirectory dir = findCentralDirectory(raf); in getZipCrc()
59 return computeCrcOfCentralDir(raf, dir); in getZipCrc()
61 raf.close(); in getZipCrc()
66 static CentralDirectory findCentralDirectory(RandomAccessFile raf) throws IOException, in findCentralDirectory() argument
68 long scanOffset = raf.length() - ENDHDR; in findCentralDirectory()
70 throw new ZipException("File too short to be a zip file: " + raf.length()); in findCentralDirectory()
80 raf.seek(scanOffset); in findCentralDirectory()
81 if (raf.readInt() == endSig) { in findCentralDirectory()
95 raf.skipBytes(2); // diskNumber in findCentralDirectory()
[all …]
/frameworks/base/telephony/java/android/telephony/
DRadioAccessFamily.java252 private static int getAdjustedRaf(int raf) { in getAdjustedRaf() argument
253 raf = ((GSM & raf) > 0) ? (GSM | raf) : raf; in getAdjustedRaf()
254 raf = ((WCDMA & raf) > 0) ? (WCDMA | raf) : raf; in getAdjustedRaf()
255 raf = ((CDMA & raf) > 0) ? (CDMA | raf) : raf; in getAdjustedRaf()
256 raf = ((EVDO & raf) > 0) ? (EVDO | raf) : raf; in getAdjustedRaf()
257 raf = ((LTE & raf) > 0) ? (LTE | raf) : raf; in getAdjustedRaf()
258 raf = ((NR & raf) > 0) ? (NR | raf) : raf; in getAdjustedRaf()
260 return raf; in getAdjustedRaf()
265 public static int getNetworkTypeFromRaf(int raf) { in getNetworkTypeFromRaf() argument
266 raf = getAdjustedRaf(raf); in getNetworkTypeFromRaf()
[all …]
/frameworks/base/core/tests/hosttests/test-apps/MultiDexLegacyTestServices/src/com/android/framework/multidexlegacytestservices/
DAbstractService.java61 RandomAccessFile raf = new RandomAccessFile(resultFile, "rw"); in run() local
62 raf.seek(raf.length()); in run()
63 if (raf.length() == 0) { in run()
64 Log.i(TAG, "Writing 0x42434445 at " + raf.length() + " in " + resultFile.getPath()); in run()
65 raf.writeInt(0x42434445); in run()
67 Log.w(TAG, "Service was restarted appending 0x42434445 twice at " + raf.length() in run()
69 raf.writeInt(0x42434445); in run()
70 raf.writeInt(0x42434445); in run()
72 raf.close(); in run()
79 raf = new RandomAccessFile(resultFile, "rw"); in run()
[all …]
/frameworks/base/packages/BackupEncryption/test/robolectric/src/com/android/server/backup/encryption/tasks/
DBackupFileDecryptorTaskTest.java194 RandomAccessFile raf = new RandomAccessFile(mInputFile, READ_WRITE_MODE); in decryptFile_withInlineLengths_throwsForZeroLengths() local
195 raf.seek(0); in decryptFile_withInlineLengths_throwsForZeroLengths()
196 raf.writeInt(0); in decryptFile_withInlineLengths_throwsForZeroLengths()
209 RandomAccessFile raf = new RandomAccessFile(mInputFile, READ_WRITE_MODE); in decryptFile_withInlineLengths_throwsForLongLengths() local
210 raf.seek(0); in decryptFile_withInlineLengths_throwsForLongLengths()
211 raf.writeInt((int) mInputFile.length()); in decryptFile_withInlineLengths_throwsForLongLengths()
281 RandomAccessFile raf = new RandomAccessFile(mInputFile, READ_WRITE_MODE); in decryptFile_throwsForBadChunksMetadataOffset() local
282 raf.seek(raf.length() - Long.BYTES); in decryptFile_throwsForBadChunksMetadataOffset()
283 int metadataOffset = (int) raf.readLong(); in decryptFile_throwsForBadChunksMetadataOffset()
284 int metadataLength = (int) raf.length() - metadataOffset - Long.BYTES; in decryptFile_throwsForBadChunksMetadataOffset()
[all …]
/frameworks/multidex/library/test/src/androidx/multidex/
DZipUtilTest.java68 RandomAccessFile raf = new RandomAccessFile(zipFile, "r"); in testCrcRange() local
69 CentralDirectory dir = ZipUtil.findCentralDirectory(raf); in testCrcRange()
73 raf.seek(dir.offset); in testCrcRange()
75 int read = raf.read(dirData, off, length); in testCrcRange()
82 raf.close(); in testCrcRange()
129 RandomAccessFile raf = new RandomAccessFile(tmp, "r"); in testCrcValue() local
132 dir.size = raf.length(); in testCrcValue()
133 long crc = ZipUtil.computeCrcOfCentralDir(raf, dir); in testCrcValue()
135 raf.close(); in testCrcValue()
159 RandomAccessFile raf = new RandomAccessFile(tmp, "r"); in testInvalidCrcValue() local
[all …]
/frameworks/base/core/tests/hosttests/test-apps/MultiDexLegacyTestServicesTests2/src/com/android/framework/multidexlegacytestservices/test2/
DServicesTests.java334 RandomAccessFile raf = new RandomAccessFile(zip, "rw"); in tamperAllExtractedZips() local
339 raf.write(zeros, 0, length); in tamperAllExtractedZips()
343 raf.close(); in tamperAllExtractedZips()
357 RandomAccessFile raf = new RandomAccessFile(odex, "rw"); in tamperAllOdex() local
359 raf.seek(savedSizeForOdexHeader); in tamperAllOdex()
360 raf.write(zeros, 0, zeros.length); in tamperAllOdex()
362 raf.close(); in tamperAllOdex()
/frameworks/base/services/core/java/com/android/server/locksettings/
DLockSettingsStorage.java343 try (RandomAccessFile raf = new RandomAccessFile(name, "r")) { in readFile() argument
344 stored = new byte[(int) raf.length()]; in readFile()
345 raf.readFully(stored, 0, stored.length); in readFile()
346 raf.close(); in readFile()
370 RandomAccessFile raf = null; in writeFile() local
376 raf = new RandomAccessFile(name, "rws"); in writeFile()
379 raf.setLength(0); in writeFile()
381 raf.write(hash, 0, hash.length); in writeFile()
383 raf.close(); in writeFile()
388 if (raf != null) { in writeFile()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DProxyController.java578 int raf = mPhones[i].getRadioAccessFamily(); in completeRadioCapabilityTransaction() local
579 logd("radioAccessFamily[" + i + "]=" + raf); in completeRadioCapabilityTransaction()
580 RadioAccessFamily phoneRC = new RadioAccessFamily(i, raf); in completeRadioCapabilityTransaction()
676 private String getLogicalModemIdFromRaf(int raf) { in getLogicalModemIdFromRaf() argument
680 if (mPhones[phoneId].getRadioAccessFamily() == raf) { in getLogicalModemIdFromRaf()
DRIL.java3124 public static int convertToNetworkTypeBitMask(int raf) { in convertToNetworkTypeBitMask() argument
3127 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.GSM) != 0) { in convertToNetworkTypeBitMask()
3130 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.GPRS) != 0) { in convertToNetworkTypeBitMask()
3133 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.EDGE) != 0) { in convertToNetworkTypeBitMask()
3137 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.IS95A) != 0) { in convertToNetworkTypeBitMask()
3140 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.IS95B) != 0) { in convertToNetworkTypeBitMask()
3143 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.ONE_X_RTT) != 0) { in convertToNetworkTypeBitMask()
3146 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.EVDO_0) != 0) { in convertToNetworkTypeBitMask()
3149 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.EVDO_A) != 0) { in convertToNetworkTypeBitMask()
3152 if ((raf & android.hardware.radio.V1_0.RadioAccessFamily.EVDO_B) != 0) { in convertToNetworkTypeBitMask()
[all …]
DSubscriptionController.java2575 int raf; in setDefaultDataSubId() local
2579 raf = proxyController.getMaxRafSupported(); in setDefaultDataSubId()
2583 raf = proxyController.getMinRafSupported(); in setDefaultDataSubId()
2586 + raf); in setDefaultDataSubId()
2587 rafs[phoneId] = new RadioAccessFamily(phoneId, raf); in setDefaultDataSubId()
/frameworks/base/core/java/android/os/
DRecoverySystem.java230 final RandomAccessFile raf = new RandomAccessFile(packageFile, "r"); in verifyPackage() local
237 raf.seek(fileLen - 6); in verifyPackage()
239 raf.readFully(footer); in verifyPackage()
249 raf.seek(fileLen - (commentSize + 22)); in verifyPackage()
250 raf.readFully(eocd); in verifyPackage()
302 raf.seek(0); in verifyPackage()
331 int read = raf.read(b, off, size); in verifyPackage()
362 raf.close(); in verifyPackage()
/frameworks/base/mime/java-res/
Dandroid.mime.types97 ?image/x-fuji-raf raf