Java Code Examples for com.android.io.IAbstractFolder#exists()
The following examples show how to use
com.android.io.IAbstractFolder#exists() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ProjectProperties.java From java-n-IDE-for-Android with Apache License 2.0 | 5 votes |
/** * Loads a project properties file and return a {@link ProjectProperties} object * containing the properties. * * @param projectFolder the project folder. * @param type One the possible {@link PropertyType}s. */ public static ProjectProperties load(IAbstractFolder projectFolder, PropertyType type) { if (projectFolder.exists()) { IAbstractFile propFile = projectFolder.getFile(type.mFilename); if (propFile.exists()) { Map<String, String> map = parsePropertyFile(propFile, null /* log */); if (map != null) { return new ProjectProperties(projectFolder, map, type); } } } return null; }
Example 2
Source File: ProjectProperties.java From java-n-IDE-for-Android with Apache License 2.0 | 5 votes |
/** * Deletes a project properties file. * * @param projectFolder the project folder. * @param type One the possible {@link PropertyType}s. * @return true if success. */ public static boolean delete(IAbstractFolder projectFolder, PropertyType type) { if (projectFolder.exists()) { IAbstractFile propFile = projectFolder.getFile(type.mFilename); if (propFile.exists()) { return propFile.delete(); } } return false; }
Example 3
Source File: ProjectProperties.java From javaide with GNU General Public License v3.0 | 5 votes |
/** * Loads a project properties file and return a {@link ProjectProperties} object * containing the properties. * * @param projectFolder the project folder. * @param type One the possible {@link PropertyType}s. */ public static ProjectProperties load(IAbstractFolder projectFolder, PropertyType type) { if (projectFolder.exists()) { IAbstractFile propFile = projectFolder.getFile(type.mFilename); if (propFile.exists()) { Map<String, String> map = parsePropertyFile(propFile, null /* log */); if (map != null) { return new ProjectProperties(projectFolder, map, type); } } } return null; }
Example 4
Source File: ProjectProperties.java From javaide with GNU General Public License v3.0 | 5 votes |
/** * Deletes a project properties file. * * @param projectFolder the project folder. * @param type One the possible {@link PropertyType}s. * @return true if success. */ public static boolean delete(IAbstractFolder projectFolder, PropertyType type) { if (projectFolder.exists()) { IAbstractFile propFile = projectFolder.getFile(type.mFilename); if (propFile.exists()) { return propFile.delete(); } } return false; }