Home
last modified time | relevance | path

Searched refs:dir (Results 1 – 25 of 219) sorted by relevance

123456789

/packages/apps/TV/common/tests/robotests/src/com/android/tv/common/util/
DCommonUtilsTest.java46 File dir = new File(RuntimeEnvironment.application.getExternalFilesDir(null), "dir"); in deleteDirOrFile_Dir() local
47 assertThat(dir.mkdirs()).isTrue(); in deleteDirOrFile_Dir()
48 assertThat(new File(dir, "file").createNewFile()).isTrue(); in deleteDirOrFile_Dir()
49 assertThat(CommonUtils.deleteDirOrFile(dir)).isTrue(); in deleteDirOrFile_Dir()
50 assertThat(dir.exists()).isFalse(); in deleteDirOrFile_Dir()
55 File dir = new File(RuntimeEnvironment.application.getExternalFilesDir(null), "dir"); in deleteDirOrFile_unreadableDir() local
56 assertThat(dir.mkdirs()).isTrue(); in deleteDirOrFile_unreadableDir()
57 assertThat(new File(dir, "file").createNewFile()).isTrue(); in deleteDirOrFile_unreadableDir()
58 dir.setReadable(false); in deleteDirOrFile_unreadableDir()
61 assertThat(CommonUtils.deleteDirOrFile(dir)).isFalse(); in deleteDirOrFile_unreadableDir()
[all …]
/packages/providers/MediaProvider/tests/src/com/android/providers/media/scan/
DMediaScannerTest.java118 final File dir = Environment.getExternalStorageDirectory(); in testCorrectness() local
119 stage(R.raw.test_audio, new File(dir, "test.mp3")); in testCorrectness()
120 stage(R.raw.test_video, new File(dir, "test.mp4")); in testCorrectness()
121 stage(R.raw.test_image, new File(dir, "test.jpg")); in testCorrectness()
124 scanDirectory(mLegacy, dir, "legacy"); in testCorrectness()
125 scanDirectory(mModern, dir, "modern"); in testCorrectness()
182 final File dir = new File(Environment.getExternalStorageDirectory(), in testSpeed() local
185 stage(dir, 4, 3); in testSpeed()
189 FileUtils.deleteContentsAndDir(dir); in testSpeed()
193 private static void scanDirectory(MediaScanner scanner, File dir, String tag) { in scanDirectory() argument
[all …]
/packages/apps/Car/libs/car-ui-lib/tests/tools/
Dquick_rro.py52 for root, dirs, files in os.walk(args.dir):
84 def get_android_dir_priority(dir): argument
89 if len(dir) == 0:
91 if 'stable' in dir:
95 return int(dir.split('-')[1])
118 for dir in os.listdir(sdk_dir):
119 if os.path.isdir(os.path.join(sdk_dir, dir)):
120 if get_android_dir_priority(dir) > get_android_dir_priority(best_dir):
121 best_dir = dir
163 resource_folder = args.dir or os.path.join(root_folder, 'res')
[all …]
/packages/services/BuiltInPrintService/src/com/android/bips/util/
DFileUtils.java57 public static boolean makeDirectory(File dir) { in makeDirectory() argument
59 Log.d(TAG, "Testing file " + dir + " exists=" + dir.exists() in makeDirectory()
60 + " isDirectory=" + dir.isDirectory()); in makeDirectory()
62 if (dir.exists()) { in makeDirectory()
63 return dir.isDirectory(); in makeDirectory()
65 return dir.mkdir(); in makeDirectory()
/packages/inputmethods/LatinIME/native/jni/src/dictionary/utils/
Dfile_utils.cpp46 DIR *const dir = opendir(dirPath); in existsDir() local
47 if (dir == NULL) { in existsDir()
50 closedir(dir); in existsDir()
61 DIR *const dir = opendir(dirPath); in removeDirAndFiles() local
62 if (dir == NULL) { in removeDirAndFiles()
67 while ((dirent = readdir(dir)) != NULL) { in removeDirAndFiles()
79 closedir(dir); in removeDirAndFiles()
83 closedir(dir); in removeDirAndFiles()
/packages/apps/Launcher3/src/com/android/launcher3/logging/
DUserEventDispatcher.java165 event.action.dir = direction; in logTaskLaunchOrDismiss()
299 public void logActionOnContainer(int action, int dir, int containerType) { in logActionOnContainer() argument
300 logActionOnContainer(action, dir, containerType, 0); in logActionOnContainer()
303 public void logActionOnContainer(int action, int dir, int containerType, int pageIndex) { in logActionOnContainer() argument
306 event.action.dir = dir; in logActionOnContainer()
318 public void logStateChangeAction(int action, int dir, int downX, int downY, in logStateChangeAction() argument
333 event.action.dir = dir; in logStateChangeAction()
342 public void logActionOnItem(int action, int dir, int itemType) { in logActionOnItem() argument
343 logActionOnItem(action, dir, itemType, null, null); in logActionOnItem()
355 public void logActionOnItem(int touchAction, int dir, int itemType, in logActionOnItem() argument
[all …]
/packages/apps/Car/libs/car-ui-lib/tests/apitest/
Dresource_utils.py70 for dir in fileDirs:
71 type = dir.split('-')[0]
72 for file in os.listdir(os.path.join(resDir, dir)):
76 ResourceLocation(os.path.join(resDir, dir, file))))
78 for dir in valuesDirs:
79 for file in os.listdir(os.path.join(resDir, dir)):
81 for resource in get_resources_from_single_file(os.path.join(resDir, dir, file)):
DAndroid.mk19 LOCAL_PATH := $(call my-dir)
22 intermediates := $(call intermediates-dir-for, PACKAGING, Android,,COMMON)
29 $(hide) mkdir -p $(dir $@) && touch $@
/packages/services/Car/tests/BugReportApp/src/com/google/android/car/bugreport/
DFileUtils.java49 File dir = new File(context.getDataDir(), PENDING_DIR); in getPendingDir() local
50 dir.mkdirs(); in getPendingDir()
51 return dir; in getPendingDir()
59 File dir = getTempDir(context, timestamp); in createTempDir() local
60 dir.mkdirs(); in createTempDir()
61 return dir; in createTempDir()
/packages/providers/MediaProvider/tests/src/com/android/providers/media/
DIdleServiceTest.java60 final File dir = Environment.getExternalStorageDirectory(); in testPruneThumbnails() local
62 new File(dir, System.nanoTime() + ".jpg")); in testPruneThumbnails()
69 final File a = buildPath(dir, Environment.DIRECTORY_PICTURES, ".thumbnails", "1234567.jpg"); in testPruneThumbnails()
70 final File b = buildPath(dir, Environment.DIRECTORY_MOVIES, ".thumbnails", "7654321.jpg"); in testPruneThumbnails()
71 final File c = buildPath(dir, Environment.DIRECTORY_PICTURES, ".thumbnails", id + ".jpg"); in testPruneThumbnails()
72 final File d = buildPath(dir, Environment.DIRECTORY_PICTURES, ".thumbnails", "random.bin"); in testPruneThumbnails()
/packages/inputmethods/LatinIME/tools/dicttool/compat/android/test/
DAndroidTestCase.java32 final File dir = Test.TEST_TMP_DIR; in getCacheDir() local
33 if (!dir.isDirectory()) { in getCacheDir()
34 dir.mkdirs(); in getCacheDir()
36 return dir; in getCacheDir()
/packages/providers/MediaProvider/src/com/android/providers/media/scan/
DModernMediaScanner.java348 public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) in preVisitDirectory() argument
353 if (isDirectoryHidden(dir.toFile())) { in preVisitDirectory()
359 return visitFile(dir, attrs); in preVisitDirectory()
423 public FileVisitResult postVisitDirectory(Path dir, IOException exc) in postVisitDirectory() argument
913 static boolean isDirectoryHiddenRecursive(File dir) { in isDirectoryHiddenRecursive() argument
916 while (dir != null) { in isDirectoryHiddenRecursive()
917 if (isDirectoryHidden(dir)) { in isDirectoryHiddenRecursive()
920 dir = dir.getParentFile(); in isDirectoryHiddenRecursive()
931 static boolean isDirectoryHidden(File dir) { in isDirectoryHidden() argument
932 final File nomedia = new File(dir, ".nomedia"); in isDirectoryHidden()
[all …]
/packages/apps/Messaging/src/com/android/messaging/util/
DDebugUtils.java229 final File dir = DebugUtils.getDebugFilesDir(); in doInBackgroundTimed() local
230 return dir.list(new FilenameFilter() { in doInBackgroundTimed()
232 public boolean accept(final File dir, final String filename) { in doInBackgroundTimed()
331 final File dir = getDebugFilesDir();
332 final File file = new File(dir, fileName);
340 final File dir = Environment.getExternalStorageDirectory();
341 return dir;
/packages/apps/Test/connectivity/sl4n/rapidjson/doc/diagram/
Dutilityclass.dot21 edge [arrowtail=onormal, dir=back]
35 edge [arrowtail=onormal, dir=back]
53 edge [arrowtail=onormal, dir=back]
58 edge [arrowtail=odiamond, arrowhead=vee, dir=both]
/packages/apps/StorageManager/src/com/android/storagemanager/deletionhelper/
DFetchDownloadsLoader.java63 static DownloadsResult collectFiles(File dir) { in collectFiles() argument
64 return collectFiles(dir, new DownloadsResult()); in collectFiles()
67 private static DownloadsResult collectFiles(File dir, DownloadsResult result) { in collectFiles() argument
71 File downloadFiles[] = dir.listFiles(); in collectFiles()
/packages/services/Car/service/src/com/android/car/storagemonitoring/
DSysfsLifetimeWriteInfoProvider.java61 private LifetimeWriteInfo tryParse(File dir) { in tryParse() argument
62 File writefile = new File(dir, FILENAME); in tryParse()
87 dir.getName(), in tryParse()
88 dir.getParentFile().getName(), in tryParse()
/packages/apps/Bluetooth/src/com/android/bluetooth/opp/
DBluetoothOppProvider.java221 Integer dir = values.getAsInteger(BluetoothShare.DIRECTION); in insert() local
224 if (dir == null) { in insert()
225 dir = BluetoothShare.DIRECTION_OUTBOUND; in insert()
227 if (dir == BluetoothShare.DIRECTION_OUTBOUND && con == null) { in insert()
230 if (dir == BluetoothShare.DIRECTION_INBOUND && con == null) { in insert()
234 filteredValues.put(BluetoothShare.DIRECTION, dir); in insert()
/packages/services/Car/car-bugreportd/
Dmain.cpp423 status_t createTempDir(const char* dir) { in createTempDir() argument
425 if (TEMP_FAILURE_RETRY(stat(dir, &sb)) == 0) { in createTempDir()
426 if (!recursiveRemoveDir(dir)) { in createTempDir()
430 ALOGE("Failed to stat %s ", dir); in createTempDir()
433 if (TEMP_FAILURE_RETRY(mkdir(dir, 0700)) == -1) { in createTempDir()
434 ALOGE("Failed to mkdir %s", dir); in createTempDir()
/packages/apps/LegacyCamera/src/com/android/camera/
DStorage.java115 File dir = new File(DIRECTORY); in getAvailableSpace() local
116 dir.mkdirs(); in getAvailableSpace()
117 if (!dir.isDirectory() || !dir.canWrite()) { in getAvailableSpace()
/packages/apps/Launcher3/src/com/android/launcher3/touch/
DSingleAxisSwipeDetector.java95 @NonNull Direction dir) { in SingleAxisSwipeDetector() argument
96 this(ViewConfiguration.get(context), l, dir, Utilities.isRtl(context.getResources())); in SingleAxisSwipeDetector()
101 @NonNull Direction dir, boolean isRtl) { in SingleAxisSwipeDetector() argument
104 mDir = dir; in SingleAxisSwipeDetector()
/packages/modules/SdkExtensions/testing/
Dupdate_prebuilt.sh23 dir=$(dirname $(readlink -f $BASH_SOURCE))
24 bps="${dir}/../framework/Android.bp"
45 cp "${OUT}/apex/com.android.sdkext/javalib/framework-sdkextensions.jar" "${dir}/test_framework-sdke…
/packages/services/Car/procfs-inspector/server/
Ddirectory.h59 void operator()(DIR* dir) { in operator()
60 if (dir) closedir(dir); in operator()
/packages/inputmethods/LatinIME/common/src/com/android/inputmethod/latin/common/
DFileUtils.java40 public static boolean deleteFilteredFiles(final File dir, final FilenameFilter fileNameFilter) { in deleteFilteredFiles() argument
41 if (!dir.isDirectory()) { in deleteFilteredFiles()
44 final File[] files = dir.listFiles(fileNameFilter); in deleteFilteredFiles()
/packages/services/Car/car-lib/
DAndroid.mk20 LOCAL_PATH:= $(call my-dir)
25 full_classes_jar := $(call intermediates-dir-for,JAVA_LIBRARIES,android.car,,COMMON)/classes.jar
33 $(hide) mkdir -p $(dir $@)
/packages/apps/DocumentsUI/src/com/android/documentsui/files/
DFilesActivity.java291 DirectoryFragment dir; in onOptionsItemSelected() local
370 DirectoryFragment dir; in onKeyShortcut() local
384 dir = getDirectoryFragment(); in onKeyShortcut()
385 if (dir != null) { in onKeyShortcut()
386 dir.pasteFromClipboard(); in onKeyShortcut()

123456789