/frameworks/base/core/tests/coretests/src/com/android/internal/os/ |
D | ProcTimeInStateReaderTest.java | 62 Path initialTimeInStateFile = mProcDirectory.toPath().resolve("initial-time-in-state"); in testSimple() 78 final Path initialTimeInStateFile = mProcDirectory.toPath().resolve( in testHeaderFormat() 95 Path initialTimeInStateFile = mProcDirectory.toPath().resolve("initial-time-in-state"); in testDifferentFile() 99 Path timeInStateFile = mProcDirectory.toPath().resolve("time-in-state"); in testDifferentFile() 109 Path initialTimeInStateFile = mProcDirectory.toPath().resolve("initial-time-in-state"); in testWrongLength() 113 Path timeInStateFile = mProcDirectory.toPath().resolve("time-in-state"); in testWrongLength() 120 Path initialTimeInStateFile = mProcDirectory.toPath().resolve("initial-time-in-state"); in testEmptyInitialFails()
|
D | ProcStatsUtilTest.java | 168 Files.write(tempFile.toPath(), fileContents.getBytes()); in runReadNullSeparatedFile() 170 Files.delete(tempFile.toPath()); in runReadNullSeparatedFile() 176 Files.write(tempFile.toPath(), fileContents.getBytes()); in runReadSingleLineProcFile() 178 Files.delete(tempFile.toPath()); in runReadSingleLineProcFile() 185 Files.write(tempFile.toPath(), fileContents.getBytes()); in runReadTerminatedProcFile() 187 Files.delete(tempFile.toPath()); in runReadTerminatedProcFile()
|
D | KernelCpuProcStringReaderTest.java | 113 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testReadErrorsLimit() 127 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testReadErrorsLimit() 148 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testReadLine() 182 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testMultipleRead() 199 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testReadLineToArray() 237 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testReadOverLimit() 255 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testConcurrent() 307 try (BufferedWriter w = Files.newBufferedWriter(mTestFile.toPath())) { in testConcurrent()
|
D | StoragedUidIoStatsReaderTest.java | 89 BufferedWriter bufferedWriter = Files.newBufferedWriter(mTestFile.toPath()); in testReadExpected() 127 BufferedWriter bufferedWriter = Files.newBufferedWriter(mTestFile.toPath()); in testLineDoesNotElevenEntries() 151 BufferedWriter bufferedWriter = Files.newBufferedWriter(mTestFile.toPath()); in testLineIsMalformed()
|
D | ProcLocksReaderTest.java | 107 Files.write(tempFile.toPath(), fileContents.getBytes()); in runHandleBlockingFileLocks() 110 Files.delete(tempFile.toPath()); in runHandleBlockingFileLocks()
|
D | BinderfsStatsReaderTest.java | 172 Files.write(tempFile.toPath(), fileContents.getBytes()); in runHandleBlockingFileLocks() 189 Files.delete(tempFile.toPath()); in runHandleBlockingFileLocks()
|
D | KernelCpuThreadReaderTest.java | 86 setupDirectory(mProcDirectory.toPath().resolve(String.valueOf(uid)), in testReader_byUids() 94 mProcDirectory.toPath(), in testReader_byUids() 95 mProcDirectory.toPath().resolve(uids[0] + "/task/" + uids[0] + "/time_in_state"), in testReader_byUids()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/ |
D | EntropyMixerTest.java | 76 Files.write(randomReadDevice.toPath(), urandomInjectedData); in testInitFirstBoot() 84 assertTrue(isDeviceSpecificInfo(Files.readAllBytes(randomWriteDevice.toPath()))); in testInitFirstBoot() 94 Files.write(seedFile.toPath(), previousSeed); in testInitNonFirstBoot() 97 Files.write(randomReadDevice.toPath(), urandomInjectedData); in testInitNonFirstBoot() 105 byte[] dataWrittenToUrandom = Files.readAllBytes(randomWriteDevice.toPath()); in testInitNonFirstBoot() 124 byte[] newSeed = Files.readAllBytes(seedFile.toPath()); in validateSeedFile()
|
/frameworks/av/media/mtp/ |
D | MtpUtils.cpp | 120 int copyRecursive(const char *fromPath, const char *toPath) { in copyRecursive() argument 123 string toPathStr(toPath); in copyRecursive() 157 int copyFile(const char *fromPath, const char *toPath) { in copyFile() argument 165 android::base::unique_fd toFd(open(toPath, O_CREAT | O_WRONLY, FILE_PERM)); in copyFile() 167 PLOG(ERROR) << "Failed to open copy to " << toPath; in copyFile() 192 chown(toPath, getuid(), FILE_GROUP); in copyFile() 193 access_ok(toPath); in copyFile()
|
D | MtpUtils.h | 34 int copyRecursive(const char *fromPath, const char *toPath); 35 int copyFile(const char *fromPath, const char *toPath);
|
/frameworks/base/core/java/android/gesture/ |
D | Gesture.java | 125 public Path toPath() { in toPath() method in Gesture 126 return toPath(null); in toPath() 129 public Path toPath(Path path) { in toPath() method in Gesture 142 public Path toPath(int width, int height, int edge, int numSample) { in toPath() method in Gesture 143 return toPath(null, width, height, edge, numSample); in toPath() 146 public Path toPath(Path path, int width, int height, int edge, int numSample) { in toPath() method in Gesture 153 path.addPath(strokes.get(i).toPath(width - 2 * edge, height - 2 * edge, numSample)); in toPath() 204 Path path = strokes.get(i).toPath(width - 2 * edge, height - 2 * edge, numSample); in toBitmap() 234 final Path path = toPath(); in toBitmap()
|
D | OrientedBoundingBox.java | 55 public Path toPath() { in toPath() method in OrientedBoundingBox
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/settings/ |
D | UserFileManagerImplTest.kt | 103 Files.createDirectories(legacyFile.getParentFile().toPath()) in testMigrateFile() 104 Files.write(legacyFile.toPath(), fileContents.toByteArray()) in testMigrateFile() 109 val newContents = String(Files.readAllBytes(file.toPath())) in testMigrateFile() 132 Files.createDirectories(legacyFile.getParentFile().toPath()) in testMigrateSharedPrefs()
|
/frameworks/base/services/core/java/com/android/server/ |
D | SystemConfig.java | 1283 boolean vendor = permFile.toPath().startsWith( in readPermissionsFromXml() 1284 Environment.getVendorDirectory().toPath() + "/") in readPermissionsFromXml() 1285 || permFile.toPath().startsWith( in readPermissionsFromXml() 1286 Environment.getOdmDirectory().toPath() + "/"); in readPermissionsFromXml() 1287 boolean product = permFile.toPath().startsWith( in readPermissionsFromXml() 1288 Environment.getProductDirectory().toPath() + "/"); in readPermissionsFromXml() 1289 boolean systemExt = permFile.toPath().startsWith( in readPermissionsFromXml() 1290 Environment.getSystemExtDirectory().toPath() + "/"); in readPermissionsFromXml() 1291 boolean apex = permFile.toPath().startsWith( in readPermissionsFromXml() 1292 Environment.getApexDirectory().toPath() + "/"); in readPermissionsFromXml() [all …]
|
/frameworks/base/packages/EncryptedLocalTransport/src/com/android/encryptedlocaltransport/ |
D | EncryptedLocalTransport.java | 70 Files.copy(in, packageFile.toPath(), StandardCopyOption.REPLACE_EXISTING); in performBackup() 94 Files.copy(packageFile.toPath(), out); in getRestoreData()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/adb/ |
D | AdbDebuggingManagerTest.java | 779 Files.delete(mAdbKeyXmlFile.toPath()); in test_notifyKeyFilesUpdated_filesDeletedRemovesPreviouslyAddedKey() 780 Files.delete(mAdbKeyFile.toPath()); in test_notifyKeyFilesUpdated_filesDeletedRemovesPreviouslyAddedKey() 798 Files.copy(mAdbKeyXmlFile.toPath(), tempXmlFile, StandardCopyOption.REPLACE_EXISTING); in test_notifyKeyFilesUpdated_newKeyIsAuthorized() 799 Files.copy(mAdbKeyFile.toPath(), tempAdbKeysFile, StandardCopyOption.REPLACE_EXISTING); in test_notifyKeyFilesUpdated_newKeyIsAuthorized() 802 Files.delete(mAdbKeyXmlFile.toPath()); in test_notifyKeyFilesUpdated_newKeyIsAuthorized() 803 Files.delete(mAdbKeyFile.toPath()); in test_notifyKeyFilesUpdated_newKeyIsAuthorized() 810 Files.copy(tempXmlFile, mAdbKeyXmlFile.toPath(), StandardCopyOption.REPLACE_EXISTING); in test_notifyKeyFilesUpdated_newKeyIsAuthorized() 811 Files.copy(tempAdbKeysFile, mAdbKeyFile.toPath(), StandardCopyOption.REPLACE_EXISTING); in test_notifyKeyFilesUpdated_newKeyIsAuthorized()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/integrity/ |
D | IntegrityFileManagerTest.java | 71 Files.walk(mTmpDir.toPath()) in setUp() 80 Files.walk(mTmpDir.toPath()) in tearDown() 87 Files.walk(mTmpDir.toPath()) in tearDown()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/assist/ui/ |
D | CornerPathRenderer.java | 62 return toPath(points); in approximateInnerPath() 90 private Path toPath(List<PointF> points) { in toPath() method in CornerPathRenderer
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pdb/ |
D | PersistentDataBlockServiceTest.java | 414 FileChannel channel = FileChannel.open(mDataBlockFile.toPath(), StandardOpenOption.WRITE, in testPartitionFormat() 430 channel = FileChannel.open(mDataBlockFile.toPath(), StandardOpenOption.READ); in testPartitionFormat() 746 byte[] secretFileData = Files.readAllBytes(mFrpSecretFile.toPath()); in frpSecret_SetSecret() 806 Files.move(mFrpSecretFile.toPath(), mFrpSecretTmpFile.toPath(), REPLACE_EXISTING); in frpState_AutomaticallyDeactivateWithBackupDataFile() 1002 Files.deleteIfExists(mFrpSecretFile.toPath()); in simulateDataWipe() 1003 Files.deleteIfExists(mFrpSecretTmpFile.toPath()); in simulateDataWipe() 1011 try (var ch = FileChannel.open(mDataBlockFile.toPath(), StandardOpenOption.WRITE)) { in tamperWithDigest() 1017 try (var ch = FileChannel.open(mDataBlockFile.toPath(), StandardOpenOption.WRITE)) { in tamperWithMagic() 1053 try (var ch = FileChannel.open(mDataBlockFile.toPath(), StandardOpenOption.READ)) { in readBackingFile()
|
/frameworks/base/core/java/android/app/backup/ |
D | BackupUtils.java | 47 if (file.toPath().startsWith(canonicalPath)) { in isFileSpecifiedInPathList()
|
/frameworks/base/services/core/java/com/android/server/security/ |
D | FileIntegrityService.java | 253 loadCertificatesFromDirectory(Environment.getRootDirectory().toPath() in loadAllCertificates() 255 loadCertificatesFromDirectory(Environment.getProductDirectory().toPath() in loadAllCertificates() 267 byte[] certificateBytes = Files.readAllBytes(cert.toPath()); in loadCertificatesFromDirectory()
|
/frameworks/base/services/core/java/com/android/server/pm/parsing/ |
D | PackageCacher.java | 143 if (packageFile.toPath().startsWith(Environment.getApexDirectory().toPath())) { in isCacheUpToDate()
|
/frameworks/av/media/mtp/tests/MtpFuzzer/ |
D | mtp_fuzzer.cpp | 150 int createDatabaseFromSourceDir(const char* fromPath, const char* toPath, in createDatabaseFromSourceDir() argument 154 std::string toPathStr(toPath); in createDatabaseFromSourceDir()
|
/frameworks/base/services/core/java/com/android/server/testharness/ |
D | TestHarnessModeService.java | 188 writeBytesToFile(persistentData.mAdbKeys, adbManager.getAdbKeysFile().toPath()); in setUpAdbFiles() 191 writeBytesToFile(persistentData.mAdbTempKeys, adbManager.getAdbTempKeysFile().toPath()); in setUpAdbFiles() 382 Path path = file.toPath(); in getBytesFromFile()
|
/frameworks/base/core/java/com/android/internal/os/ |
D | StoragedUidIoStatsReader.java | 88 try (BufferedReader reader = Files.newBufferedReader(file.toPath())) { in readAbsoluteInternal()
|