PageRenderTime 69ms CodeModel.GetById 30ms RepoModel.GetById 0ms app.codeStats 0ms

/third-party/java/aosp/src/com/android/common/SdkConstants.java

https://github.com/atsoi/buck
Java | 1138 lines | 639 code | 159 blank | 340 comment | 15 complexity | 793ea7ff5f4e232b6b6b2b5a4312feab MD5 | raw file
Possible License(s): Apache-2.0, BSD-3-Clause

Large files files are truncated, but you can click here to view the full file

  1. /*
  2. * Copyright (C) 2007 The Android Open Source Project
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. package com.android.common;
  17. import java.io.File;
  18. /**
  19. * Constant definition class.<br>
  20. * <br>
  21. * Most constants have a prefix defining the content.
  22. * <ul>
  23. * <li><code>OS_</code> OS path constant. These paths are different depending on the platform.</li>
  24. * <li><code>FN_</code> File name constant.</li>
  25. * <li><code>FD_</code> Folder name constant.</li>
  26. * <li><code>TAG_</code> XML element tag name</li>
  27. * <li><code>ATTR_</code> XML attribute name</li>
  28. * <li><code>VALUE_</code> XML attribute value</li>
  29. * <li><code>CLASS_</code> Class name</li>
  30. * <li><code>DOT_</code> File name extension, including the dot </li>
  31. * <li><code>EXT_</code> File name extension, without the dot </li>
  32. * </ul>
  33. */
  34. @SuppressWarnings("javadoc") // Not documenting all the fields here
  35. public final class SdkConstants {
  36. public static final int PLATFORM_UNKNOWN = 0;
  37. public static final int PLATFORM_LINUX = 1;
  38. public static final int PLATFORM_WINDOWS = 2;
  39. public static final int PLATFORM_DARWIN = 3;
  40. /**
  41. * Returns current platform, one of {@link #PLATFORM_WINDOWS}, {@link #PLATFORM_DARWIN},
  42. * {@link #PLATFORM_LINUX} or {@link #PLATFORM_UNKNOWN}.
  43. */
  44. public static final int CURRENT_PLATFORM = currentPlatform();
  45. /**
  46. * Charset for the ini file handled by the SDK.
  47. */
  48. public static final String INI_CHARSET = "UTF-8"; //$NON-NLS-1$
  49. /** An SDK Project's AndroidManifest.xml file */
  50. public static final String FN_ANDROID_MANIFEST_XML= "AndroidManifest.xml"; //$NON-NLS-1$
  51. /** pre-dex jar filename. i.e. "classes.jar" */
  52. public static final String FN_CLASSES_JAR = "classes.jar"; //$NON-NLS-1$
  53. /** Dex filename inside the APK. i.e. "classes.dex" */
  54. public static final String FN_APK_CLASSES_DEX = "classes.dex"; //$NON-NLS-1$
  55. /** An SDK Project's build.xml file */
  56. public static final String FN_BUILD_XML = "build.xml"; //$NON-NLS-1$
  57. /** Name of the framework library, i.e. "android.jar" */
  58. public static final String FN_FRAMEWORK_LIBRARY = "android.jar"; //$NON-NLS-1$
  59. /** Name of the framework library, i.e. "uiautomator.jar" */
  60. public static final String FN_UI_AUTOMATOR_LIBRARY = "uiautomator.jar"; //$NON-NLS-1$
  61. /** Name of the layout attributes, i.e. "attrs.xml" */
  62. public static final String FN_ATTRS_XML = "attrs.xml"; //$NON-NLS-1$
  63. /** Name of the layout attributes, i.e. "attrs_manifest.xml" */
  64. public static final String FN_ATTRS_MANIFEST_XML = "attrs_manifest.xml"; //$NON-NLS-1$
  65. /** framework aidl import file */
  66. public static final String FN_FRAMEWORK_AIDL = "framework.aidl"; //$NON-NLS-1$
  67. /** framework renderscript folder */
  68. public static final String FN_FRAMEWORK_RENDERSCRIPT = "renderscript"; //$NON-NLS-1$
  69. /** framework include folder */
  70. public static final String FN_FRAMEWORK_INCLUDE = "include"; //$NON-NLS-1$
  71. /** framework include (clang) folder */
  72. public static final String FN_FRAMEWORK_INCLUDE_CLANG = "clang-include"; //$NON-NLS-1$
  73. /** layoutlib.jar file */
  74. public static final String FN_LAYOUTLIB_JAR = "layoutlib.jar"; //$NON-NLS-1$
  75. /** widget list file */
  76. public static final String FN_WIDGETS = "widgets.txt"; //$NON-NLS-1$
  77. /** Intent activity actions list file */
  78. public static final String FN_INTENT_ACTIONS_ACTIVITY = "activity_actions.txt"; //$NON-NLS-1$
  79. /** Intent broadcast actions list file */
  80. public static final String FN_INTENT_ACTIONS_BROADCAST = "broadcast_actions.txt"; //$NON-NLS-1$
  81. /** Intent service actions list file */
  82. public static final String FN_INTENT_ACTIONS_SERVICE = "service_actions.txt"; //$NON-NLS-1$
  83. /** Intent category list file */
  84. public static final String FN_INTENT_CATEGORIES = "categories.txt"; //$NON-NLS-1$
  85. /** annotations support jar */
  86. public static final String FN_ANNOTATIONS_JAR = "annotations.jar"; //$NON-NLS-1$
  87. /** platform build property file */
  88. public static final String FN_BUILD_PROP = "build.prop"; //$NON-NLS-1$
  89. /** plugin properties file */
  90. public static final String FN_PLUGIN_PROP = "plugin.prop"; //$NON-NLS-1$
  91. /** add-on manifest file */
  92. public static final String FN_MANIFEST_INI = "manifest.ini"; //$NON-NLS-1$
  93. /** add-on layout device XML file. */
  94. public static final String FN_DEVICES_XML = "devices.xml"; //$NON-NLS-1$
  95. /** hardware properties definition file */
  96. public static final String FN_HARDWARE_INI = "hardware-properties.ini"; //$NON-NLS-1$
  97. /** project property file */
  98. public static final String FN_PROJECT_PROPERTIES = "project.properties"; //$NON-NLS-1$
  99. /** project local property file */
  100. public static final String FN_LOCAL_PROPERTIES = "local.properties"; //$NON-NLS-1$
  101. /** project ant property file */
  102. public static final String FN_ANT_PROPERTIES = "ant.properties"; //$NON-NLS-1$
  103. /** Skin layout file */
  104. public static final String FN_SKIN_LAYOUT = "layout"; //$NON-NLS-1$
  105. /** dx.jar file */
  106. public static final String FN_DX_JAR = "dx.jar"; //$NON-NLS-1$
  107. /** dx executable (with extension for the current OS) */
  108. public static final String FN_DX =
  109. "dx" + ext(".bat", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  110. /** aapt executable (with extension for the current OS) */
  111. public static final String FN_AAPT =
  112. "aapt" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  113. /** aidl executable (with extension for the current OS) */
  114. public static final String FN_AIDL =
  115. "aidl" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  116. /** renderscript executable (with extension for the current OS) */
  117. public static final String FN_RENDERSCRIPT =
  118. "llvm-rs-cc" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  119. /** adb executable (with extension for the current OS) */
  120. public static final String FN_ADB =
  121. "adb" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  122. /** emulator executable for the current OS */
  123. public static final String FN_EMULATOR =
  124. "emulator" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  125. /** zipalign executable (with extension for the current OS) */
  126. public static final String FN_ZIPALIGN =
  127. "zipalign" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  128. /** dexdump executable (with extension for the current OS) */
  129. public static final String FN_DEXDUMP =
  130. "dexdump" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  131. /** proguard executable (with extension for the current OS) */
  132. public static final String FN_PROGUARD =
  133. "proguard" + ext(".bat", ".sh"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  134. /** find_lock for Windows (with extension for the current OS) */
  135. public static final String FN_FIND_LOCK =
  136. "find_lock" + ext(".exe", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
  137. /** properties file for SDK Updater packages */
  138. public static final String FN_SOURCE_PROP = "source.properties"; //$NON-NLS-1$
  139. /** properties file for content hash of installed packages */
  140. public static final String FN_CONTENT_HASH_PROP = "content_hash.properties"; //$NON-NLS-1$
  141. /** properties file for the SDK */
  142. public static final String FN_SDK_PROP = "sdk.properties"; //$NON-NLS-1$
  143. /**
  144. * filename for gdbserver.
  145. */
  146. public static final String FN_GDBSERVER = "gdbserver"; //$NON-NLS-1$
  147. /** global Android proguard config file */
  148. public static final String FN_ANDROID_PROGUARD_FILE = "proguard-android.txt"; //$NON-NLS-1$
  149. /** global Android proguard config file with optimization enabled */
  150. public static final String FN_ANDROID_OPT_PROGUARD_FILE = "proguard-android-optimize.txt"; //$NON-NLS-1$
  151. /** default proguard config file with new file extension (for project specific stuff) */
  152. public static final String FN_PROJECT_PROGUARD_FILE = "proguard-project.txt"; //$NON-NLS-1$
  153. /* Folder Names for Android Projects . */
  154. /** Resources folder name, i.e. "res". */
  155. public static final String FD_RESOURCES = "res"; //$NON-NLS-1$
  156. /** Assets folder name, i.e. "assets" */
  157. public static final String FD_ASSETS = "assets"; //$NON-NLS-1$
  158. /** Default source folder name in an SDK project, i.e. "src".
  159. * <p/>
  160. * Note: this is not the same as {@link #FD_PKG_SOURCES}
  161. * which is an SDK sources folder for packages. */
  162. public static final String FD_SOURCES = "src"; //$NON-NLS-1$
  163. /** Default generated source folder name, i.e. "gen" */
  164. public static final String FD_GEN_SOURCES = "gen"; //$NON-NLS-1$
  165. /** Default native library folder name inside the project, i.e. "libs"
  166. * While the folder inside the .apk is "lib", we call that one libs because
  167. * that's what we use in ant for both .jar and .so and we need to make the 2 development ways
  168. * compatible. */
  169. public static final String FD_NATIVE_LIBS = "libs"; //$NON-NLS-1$
  170. /** Native lib folder inside the APK: "lib" */
  171. public static final String FD_APK_NATIVE_LIBS = "lib"; //$NON-NLS-1$
  172. /** Default output folder name, i.e. "bin" */
  173. public static final String FD_OUTPUT = "bin"; //$NON-NLS-1$
  174. /** Classes output folder name, i.e. "classes" */
  175. public static final String FD_CLASSES_OUTPUT = "classes"; //$NON-NLS-1$
  176. /** proguard output folder for mapping, etc.. files */
  177. public static final String FD_PROGUARD = "proguard"; //$NON-NLS-1$
  178. /** aidl output folder for copied aidl files */
  179. public static final String FD_AIDL = "aidl"; //$NON-NLS-1$
  180. /* Folder Names for the Android SDK */
  181. /** Name of the SDK platforms folder. */
  182. public static final String FD_PLATFORMS = "platforms"; //$NON-NLS-1$
  183. /** Name of the SDK addons folder. */
  184. public static final String FD_ADDONS = "add-ons"; //$NON-NLS-1$
  185. /** Name of the SDK system-images folder. */
  186. public static final String FD_SYSTEM_IMAGES = "system-images"; //$NON-NLS-1$
  187. /** Name of the SDK sources folder where source packages are installed.
  188. * <p/>
  189. * Note this is not the same as {@link #FD_SOURCES} which is the folder name where sources
  190. * are installed inside a project. */
  191. public static final String FD_PKG_SOURCES = "sources"; //$NON-NLS-1$
  192. /** Name of the SDK tools folder. */
  193. public static final String FD_TOOLS = "tools"; //$NON-NLS-1$
  194. /** Name of the SDK tools/support folder. */
  195. public static final String FD_SUPPORT = "support"; //$NON-NLS-1$
  196. /** Name of the SDK platform tools folder. */
  197. public static final String FD_PLATFORM_TOOLS = "platform-tools"; //$NON-NLS-1$
  198. /** Name of the SDK tools/lib folder. */
  199. public static final String FD_LIB = "lib"; //$NON-NLS-1$
  200. /** Name of the SDK docs folder. */
  201. public static final String FD_DOCS = "docs"; //$NON-NLS-1$
  202. /** Name of the doc folder containing API reference doc (javadoc) */
  203. public static final String FD_DOCS_REFERENCE = "reference"; //$NON-NLS-1$
  204. /** Name of the SDK images folder. */
  205. public static final String FD_IMAGES = "images"; //$NON-NLS-1$
  206. /** Name of the ABI to support. */
  207. public static final String ABI_ARMEABI = "armeabi"; //$NON-NLS-1$
  208. public static final String ABI_ARMEABI_V7A = "armeabi-v7a"; //$NON-NLS-1$
  209. public static final String ABI_INTEL_ATOM = "x86"; //$NON-NLS-1$
  210. public static final String ABI_MIPS = "mips"; //$NON-NLS-1$
  211. /** Name of the CPU arch to support. */
  212. public static final String CPU_ARCH_ARM = "arm"; //$NON-NLS-1$
  213. public static final String CPU_ARCH_INTEL_ATOM = "x86"; //$NON-NLS-1$
  214. public static final String CPU_ARCH_MIPS = "mips"; //$NON-NLS-1$
  215. /** Name of the CPU model to support. */
  216. public static final String CPU_MODEL_CORTEX_A8 = "cortex-a8"; //$NON-NLS-1$
  217. /** Name of the SDK skins folder. */
  218. public static final String FD_SKINS = "skins"; //$NON-NLS-1$
  219. /** Name of the SDK samples folder. */
  220. public static final String FD_SAMPLES = "samples"; //$NON-NLS-1$
  221. /** Name of the SDK extras folder. */
  222. public static final String FD_EXTRAS = "extras"; //$NON-NLS-1$
  223. /**
  224. * Name of an extra's sample folder.
  225. * Ideally extras should have one {@link #FD_SAMPLES} folder containing
  226. * one or more sub-folders (one per sample). However some older extras
  227. * might contain a single "sample" folder with directly the samples files
  228. * in it. When possible we should encourage extras' owners to move to the
  229. * multi-samples format.
  230. */
  231. public static final String FD_SAMPLE = "sample"; //$NON-NLS-1$
  232. /** Name of the SDK templates folder, i.e. "templates" */
  233. public static final String FD_TEMPLATES = "templates"; //$NON-NLS-1$
  234. /** Name of the SDK Ant folder, i.e. "ant" */
  235. public static final String FD_ANT = "ant"; //$NON-NLS-1$
  236. /** Name of the SDK data folder, i.e. "data" */
  237. public static final String FD_DATA = "data"; //$NON-NLS-1$
  238. /** Name of the SDK renderscript folder, i.e. "rs" */
  239. public static final String FD_RENDERSCRIPT = "rs"; //$NON-NLS-1$
  240. /** Name of the SDK resources folder, i.e. "res" */
  241. public static final String FD_RES = "res"; //$NON-NLS-1$
  242. /** Name of the SDK font folder, i.e. "fonts" */
  243. public static final String FD_FONTS = "fonts"; //$NON-NLS-1$
  244. /** Name of the android sources directory */
  245. public static final String FD_ANDROID_SOURCES = "sources"; //$NON-NLS-1$
  246. /** Name of the addon libs folder. */
  247. public static final String FD_ADDON_LIBS = "libs"; //$NON-NLS-1$
  248. /** Name of the cache folder in the $HOME/.android. */
  249. public static final String FD_CACHE = "cache"; //$NON-NLS-1$
  250. /** API codename of a release (non preview) system image or platform. **/
  251. public static final String CODENAME_RELEASE = "REL"; //$NON-NLS-1$
  252. /** Namespace for the resource XML, i.e. "http://schemas.android.com/apk/res/android" */
  253. public static final String NS_RESOURCES =
  254. "http://schemas.android.com/apk/res/android"; //$NON-NLS-1$
  255. /** Namespace for the device schema, i.e. "http://schemas.android.com/sdk/devices/1" */
  256. public static final String NS_DEVICES_XSD =
  257. "http://schemas.android.com/sdk/devices/1"; //$NON-NLS-1$
  258. /** The name of the uses-library that provides "android.test.runner" */
  259. public static final String ANDROID_TEST_RUNNER_LIB =
  260. "android.test.runner"; //$NON-NLS-1$
  261. /* Folder path relative to the SDK root */
  262. /** Path of the documentation directory relative to the sdk folder.
  263. * This is an OS path, ending with a separator. */
  264. public static final String OS_SDK_DOCS_FOLDER = FD_DOCS + File.separator;
  265. /** Path of the tools directory relative to the sdk folder, or to a platform folder.
  266. * This is an OS path, ending with a separator. */
  267. public static final String OS_SDK_TOOLS_FOLDER = FD_TOOLS + File.separator;
  268. /** Path of the lib directory relative to the sdk folder, or to a platform folder.
  269. * This is an OS path, ending with a separator. */
  270. public static final String OS_SDK_TOOLS_LIB_FOLDER =
  271. OS_SDK_TOOLS_FOLDER + FD_LIB + File.separator;
  272. /**
  273. * Path of the lib directory relative to the sdk folder, or to a platform
  274. * folder. This is an OS path, ending with a separator.
  275. */
  276. public static final String OS_SDK_TOOLS_LIB_EMULATOR_FOLDER = OS_SDK_TOOLS_LIB_FOLDER
  277. + "emulator" + File.separator; //$NON-NLS-1$
  278. /** Path of the platform tools directory relative to the sdk folder.
  279. * This is an OS path, ending with a separator. */
  280. public static final String OS_SDK_PLATFORM_TOOLS_FOLDER = FD_PLATFORM_TOOLS + File.separator;
  281. /** Path of the Platform tools Lib directory relative to the sdk folder.
  282. * This is an OS path, ending with a separator. */
  283. public static final String OS_SDK_PLATFORM_TOOLS_LIB_FOLDER =
  284. OS_SDK_PLATFORM_TOOLS_FOLDER + FD_LIB + File.separator;
  285. /** Path of the bin folder of proguard folder relative to the sdk folder.
  286. * This is an OS path, ending with a separator. */
  287. public static final String OS_SDK_TOOLS_PROGUARD_BIN_FOLDER =
  288. SdkConstants.OS_SDK_TOOLS_FOLDER +
  289. "proguard" + File.separator + //$NON-NLS-1$
  290. "bin" + File.separator; //$NON-NLS-1$
  291. /* Folder paths relative to a platform or add-on folder */
  292. /** Path of the images directory relative to a platform or addon folder.
  293. * This is an OS path, ending with a separator. */
  294. public static final String OS_IMAGES_FOLDER = FD_IMAGES + File.separator;
  295. /** Path of the skin directory relative to a platform or addon folder.
  296. * This is an OS path, ending with a separator. */
  297. public static final String OS_SKINS_FOLDER = FD_SKINS + File.separator;
  298. /* Folder paths relative to a Platform folder */
  299. /** Path of the data directory relative to a platform folder.
  300. * This is an OS path, ending with a separator. */
  301. public static final String OS_PLATFORM_DATA_FOLDER = FD_DATA + File.separator;
  302. /** Path of the renderscript directory relative to a platform folder.
  303. * This is an OS path, ending with a separator. */
  304. public static final String OS_PLATFORM_RENDERSCRIPT_FOLDER = FD_RENDERSCRIPT + File.separator;
  305. /** Path of the samples directory relative to a platform folder.
  306. * This is an OS path, ending with a separator. */
  307. public static final String OS_PLATFORM_SAMPLES_FOLDER = FD_SAMPLES + File.separator;
  308. /** Path of the resources directory relative to a platform folder.
  309. * This is an OS path, ending with a separator. */
  310. public static final String OS_PLATFORM_RESOURCES_FOLDER =
  311. OS_PLATFORM_DATA_FOLDER + FD_RES + File.separator;
  312. /** Path of the fonts directory relative to a platform folder.
  313. * This is an OS path, ending with a separator. */
  314. public static final String OS_PLATFORM_FONTS_FOLDER =
  315. OS_PLATFORM_DATA_FOLDER + FD_FONTS + File.separator;
  316. /** Path of the android source directory relative to a platform folder.
  317. * This is an OS path, ending with a separator. */
  318. public static final String OS_PLATFORM_SOURCES_FOLDER = FD_ANDROID_SOURCES + File.separator;
  319. /** Path of the android templates directory relative to a platform folder.
  320. * This is an OS path, ending with a separator. */
  321. public static final String OS_PLATFORM_TEMPLATES_FOLDER = FD_TEMPLATES + File.separator;
  322. /** Path of the Ant build rules directory relative to a platform folder.
  323. * This is an OS path, ending with a separator. */
  324. public static final String OS_PLATFORM_ANT_FOLDER = FD_ANT + File.separator;
  325. /** Path of the attrs.xml file relative to a platform folder. */
  326. public static final String OS_PLATFORM_ATTRS_XML =
  327. OS_PLATFORM_RESOURCES_FOLDER + SdkConstants.FD_RES_VALUES + File.separator +
  328. FN_ATTRS_XML;
  329. /** Path of the attrs_manifest.xml file relative to a platform folder. */
  330. public static final String OS_PLATFORM_ATTRS_MANIFEST_XML =
  331. OS_PLATFORM_RESOURCES_FOLDER + SdkConstants.FD_RES_VALUES + File.separator +
  332. FN_ATTRS_MANIFEST_XML;
  333. /** Path of the layoutlib.jar file relative to a platform folder. */
  334. public static final String OS_PLATFORM_LAYOUTLIB_JAR =
  335. OS_PLATFORM_DATA_FOLDER + FN_LAYOUTLIB_JAR;
  336. /** Path of the renderscript include folder relative to a platform folder. */
  337. public static final String OS_FRAMEWORK_RS =
  338. FN_FRAMEWORK_RENDERSCRIPT + File.separator + FN_FRAMEWORK_INCLUDE;
  339. /** Path of the renderscript (clang) include folder relative to a platform folder. */
  340. public static final String OS_FRAMEWORK_RS_CLANG =
  341. FN_FRAMEWORK_RENDERSCRIPT + File.separator + FN_FRAMEWORK_INCLUDE_CLANG;
  342. /* Folder paths relative to a addon folder */
  343. /** Path of the images directory relative to a folder folder.
  344. * This is an OS path, ending with a separator. */
  345. public static final String OS_ADDON_LIBS_FOLDER = FD_ADDON_LIBS + File.separator;
  346. /** Skin default **/
  347. public static final String SKIN_DEFAULT = "default"; //$NON-NLS-1$
  348. /** SDK property: ant templates revision */
  349. public static final String PROP_SDK_ANT_TEMPLATES_REVISION =
  350. "sdk.ant.templates.revision"; //$NON-NLS-1$
  351. /** SDK property: default skin */
  352. public static final String PROP_SDK_DEFAULT_SKIN = "sdk.skin.default"; //$NON-NLS-1$
  353. /* Android Class Constants */
  354. public static final String CLASS_ACTIVITY = "android.app.Activity"; //$NON-NLS-1$
  355. public static final String CLASS_APPLICATION = "android.app.Application"; //$NON-NLS-1$
  356. public static final String CLASS_SERVICE = "android.app.Service"; //$NON-NLS-1$
  357. public static final String CLASS_BROADCASTRECEIVER = "android.content.BroadcastReceiver"; //$NON-NLS-1$
  358. public static final String CLASS_CONTENTPROVIDER = "android.content.ContentProvider"; //$NON-NLS-1$
  359. public static final String CLASS_INSTRUMENTATION = "android.app.Instrumentation"; //$NON-NLS-1$
  360. public static final String CLASS_INSTRUMENTATION_RUNNER =
  361. "android.test.InstrumentationTestRunner"; //$NON-NLS-1$
  362. public static final String CLASS_BUNDLE = "android.os.Bundle"; //$NON-NLS-1$
  363. public static final String CLASS_R = "android.R"; //$NON-NLS-1$
  364. public static final String CLASS_MANIFEST_PERMISSION = "android.Manifest$permission"; //$NON-NLS-1$
  365. public static final String CLASS_INTENT = "android.content.Intent"; //$NON-NLS-1$
  366. public static final String CLASS_CONTEXT = "android.content.Context"; //$NON-NLS-1$
  367. public static final String CLASS_VIEW = "android.view.View"; //$NON-NLS-1$
  368. public static final String CLASS_VIEWGROUP = "android.view.ViewGroup"; //$NON-NLS-1$
  369. public static final String CLASS_NAME_LAYOUTPARAMS = "LayoutParams"; //$NON-NLS-1$
  370. public static final String CLASS_VIEWGROUP_LAYOUTPARAMS =
  371. CLASS_VIEWGROUP + "$" + CLASS_NAME_LAYOUTPARAMS; //$NON-NLS-1$
  372. public static final String CLASS_NAME_FRAMELAYOUT = "FrameLayout"; //$NON-NLS-1$
  373. public static final String CLASS_FRAMELAYOUT =
  374. "android.widget." + CLASS_NAME_FRAMELAYOUT; //$NON-NLS-1$
  375. public static final String CLASS_PREFERENCE = "android.preference.Preference"; //$NON-NLS-1$
  376. public static final String CLASS_NAME_PREFERENCE_SCREEN = "PreferenceScreen"; //$NON-NLS-1$
  377. public static final String CLASS_PREFERENCES =
  378. "android.preference." + CLASS_NAME_PREFERENCE_SCREEN; //$NON-NLS-1$
  379. public static final String CLASS_PREFERENCEGROUP = "android.preference.PreferenceGroup"; //$NON-NLS-1$
  380. public static final String CLASS_PARCELABLE = "android.os.Parcelable"; //$NON-NLS-1$
  381. public static final String CLASS_FRAGMENT = "android.app.Fragment"; //$NON-NLS-1$
  382. public static final String CLASS_V4_FRAGMENT = "android.support.v4.app.Fragment"; //$NON-NLS-1$
  383. /** MockView is part of the layoutlib bridge and used to display classes that have
  384. * no rendering in the graphical layout editor. */
  385. public static final String CLASS_MOCK_VIEW = "com.android.layoutlib.bridge.MockView"; //$NON-NLS-1$
  386. /** Returns the appropriate name for the 'android' command, which is 'android.exe' for
  387. * Windows and 'android' for all other platforms. */
  388. public static String androidCmdName() {
  389. String os = System.getProperty("os.name"); //$NON-NLS-1$
  390. String cmd = "android"; //$NON-NLS-1$
  391. if (os.startsWith("Windows")) { //$NON-NLS-1$
  392. cmd += ".bat"; //$NON-NLS-1$
  393. }
  394. return cmd;
  395. }
  396. /** Returns the appropriate name for the 'mksdcard' command, which is 'mksdcard.exe' for
  397. * Windows and 'mkdsdcard' for all other platforms. */
  398. public static String mkSdCardCmdName() {
  399. String os = System.getProperty("os.name"); //$NON-NLS-1$
  400. String cmd = "mksdcard"; //$NON-NLS-1$
  401. if (os.startsWith("Windows")) { //$NON-NLS-1$
  402. cmd += ".exe"; //$NON-NLS-1$
  403. }
  404. return cmd;
  405. }
  406. /**
  407. * Returns current platform
  408. *
  409. * @return one of {@link #PLATFORM_WINDOWS}, {@link #PLATFORM_DARWIN},
  410. * {@link #PLATFORM_LINUX} or {@link #PLATFORM_UNKNOWN}.
  411. */
  412. public static int currentPlatform() {
  413. String os = System.getProperty("os.name"); //$NON-NLS-1$
  414. if (os.startsWith("Mac OS")) { //$NON-NLS-1$
  415. return PLATFORM_DARWIN;
  416. } else if (os.startsWith("Windows")) { //$NON-NLS-1$
  417. return PLATFORM_WINDOWS;
  418. } else if (os.startsWith("Linux")) { //$NON-NLS-1$
  419. return PLATFORM_LINUX;
  420. }
  421. return PLATFORM_UNKNOWN;
  422. }
  423. /**
  424. * Returns current platform's UI name
  425. *
  426. * @return one of "Windows", "Mac OS X", "Linux" or "other".
  427. */
  428. public static String currentPlatformName() {
  429. String os = System.getProperty("os.name"); //$NON-NLS-1$
  430. if (os.startsWith("Mac OS")) { //$NON-NLS-1$
  431. return "Mac OS X"; //$NON-NLS-1$
  432. } else if (os.startsWith("Windows")) { //$NON-NLS-1$
  433. return "Windows"; //$NON-NLS-1$
  434. } else if (os.startsWith("Linux")) { //$NON-NLS-1$
  435. return "Linux"; //$NON-NLS-1$
  436. }
  437. return "Other";
  438. }
  439. private static String ext(String windowsExtension, String nonWindowsExtension) {
  440. if (CURRENT_PLATFORM == PLATFORM_WINDOWS) {
  441. return windowsExtension;
  442. } else {
  443. return nonWindowsExtension;
  444. }
  445. }
  446. /** Default anim resource folder name, i.e. "anim" */
  447. public static final String FD_RES_ANIM = "anim"; //$NON-NLS-1$
  448. /** Default animator resource folder name, i.e. "animator" */
  449. public static final String FD_RES_ANIMATOR = "animator"; //$NON-NLS-1$
  450. /** Default color resource folder name, i.e. "color" */
  451. public static final String FD_RES_COLOR = "color"; //$NON-NLS-1$
  452. /** Default drawable resource folder name, i.e. "drawable" */
  453. public static final String FD_RES_DRAWABLE = "drawable"; //$NON-NLS-1$
  454. /** Default interpolator resource folder name, i.e. "interpolator" */
  455. public static final String FD_RES_INTERPOLATOR = "interpolator"; //$NON-NLS-1$
  456. /** Default layout resource folder name, i.e. "layout" */
  457. public static final String FD_RES_LAYOUT = "layout"; //$NON-NLS-1$
  458. /** Default menu resource folder name, i.e. "menu" */
  459. public static final String FD_RES_MENU = "menu"; //$NON-NLS-1$
  460. /** Default menu resource folder name, i.e. "mipmap" */
  461. public static final String FD_RES_MIPMAP = "mipmap"; //$NON-NLS-1$
  462. /** Default values resource folder name, i.e. "values" */
  463. public static final String FD_RES_VALUES = "values"; //$NON-NLS-1$
  464. /** Default xml resource folder name, i.e. "xml" */
  465. public static final String FD_RES_XML = "xml"; //$NON-NLS-1$
  466. /** Default raw resource folder name, i.e. "raw" */
  467. public static final String FD_RES_RAW = "raw"; //$NON-NLS-1$
  468. /** Separator between the resource folder qualifier. */
  469. public static final String RES_QUALIFIER_SEP = "-"; //$NON-NLS-1$
  470. /** Namespace used in XML files for Android attributes */
  471. // ---- XML ----
  472. /** URI of the reserved "xmlns" prefix */
  473. public static final String XMLNS_URI = "http://www.w3.org/2000/xmlns/"; //$NON-NLS-1$
  474. /** The "xmlns" attribute name */
  475. public static final String XMLNS = "xmlns"; //$NON-NLS-1$
  476. /** The default prefix used for the {@link #XMLNS_URI} */
  477. public static final String XMLNS_PREFIX = "xmlns:"; //$NON-NLS-1$
  478. /** Qualified name of the xmlns android declaration element */
  479. public static final String XMLNS_ANDROID = "xmlns:android"; //$NON-NLS-1$
  480. /** The default prefix used for the {@link #ANDROID_URI} name space */
  481. public static final String ANDROID_NS_NAME = "android"; //$NON-NLS-1$
  482. /** The default prefix used for the {@link #ANDROID_URI} name space including the colon */
  483. public static final String ANDROID_NS_NAME_PREFIX = "android:"; //$NON-NLS-1$
  484. /** The default prefix used for the app */
  485. public static final String APP_PREFIX = "app"; //$NON-NLS-1$
  486. /** The entity for the ampersand character */
  487. public static final String AMP_ENTITY = "&amp;"; //$NON-NLS-1$
  488. /** The entity for the quote character */
  489. public static final String QUOT_ENTITY = "&quot;"; //$NON-NLS-1$
  490. /** The entity for the apostrophe character */
  491. public static final String APOS_ENTITY = "&apos;"; //$NON-NLS-1$
  492. /** The entity for the less than character */
  493. public static final String LT_ENTITY = "&lt;"; //$NON-NLS-1$
  494. /** The entity for the greater than character */
  495. public static final String GT_ENTITY = "&gt;"; //$NON-NLS-1$
  496. // ---- Elements and Attributes ----
  497. /** Namespace prefix used for all resources */
  498. public static final String URI_PREFIX =
  499. "http://schemas.android.com/apk/res/"; //$NON-NLS-1$
  500. /** Namespace used in XML files for Android attributes */
  501. public static final String ANDROID_URI =
  502. "http://schemas.android.com/apk/res/android"; //$NON-NLS-1$
  503. /** Namespace used in XML files for Android Tooling attributes */
  504. public static final String TOOLS_URI =
  505. "http://schemas.android.com/tools"; //$NON-NLS-1$
  506. /** Namespace used for auto-adjusting namespaces */
  507. public static final String AUTO_URI =
  508. "http://schemas.android.com/apk/res-auto"; //$NON-NLS-1$
  509. /** Default prefix used for tools attributes */
  510. public static final String TOOLS_PREFIX = "tools"; //$NON-NLS-1$
  511. public static final String R_CLASS = "R"; //$NON-NLS-1$
  512. public static final String ANDROID_PKG = "android"; //$NON-NLS-1$
  513. // Tags: Manifest
  514. public static final String TAG_SERVICE = "service"; //$NON-NLS-1$
  515. public static final String TAG_USES_PERMISSION = "uses-permission";//$NON-NLS-1$
  516. public static final String TAG_USES_LIBRARY = "uses-library"; //$NON-NLS-1$
  517. public static final String TAG_APPLICATION = "application"; //$NON-NLS-1$
  518. public static final String TAG_INTENT_FILTER = "intent-filter"; //$NON-NLS-1$
  519. public static final String TAG_USES_SDK = "uses-sdk"; //$NON-NLS-1$
  520. public static final String TAG_ACTIVITY = "activity"; //$NON-NLS-1$
  521. public static final String TAG_RECEIVER = "receiver"; //$NON-NLS-1$
  522. public static final String TAG_PROVIDER = "provider"; //$NON-NLS-1$
  523. public static final String TAG_GRANT_PERMISSION = "grant-uri-permission"; //$NON-NLS-1$
  524. public static final String TAG_PATH_PERMISSION = "path-permission"; //$NON-NLS-1$
  525. // Tags: Resources
  526. public static final String TAG_RESOURCES = "resources"; //$NON-NLS-1$
  527. public static final String TAG_STRING = "string"; //$NON-NLS-1$
  528. public static final String TAG_ARRAY = "array"; //$NON-NLS-1$
  529. public static final String TAG_STYLE = "style"; //$NON-NLS-1$
  530. public static final String TAG_ITEM = "item"; //$NON-NLS-1$
  531. public static final String TAG_STRING_ARRAY = "string-array"; //$NON-NLS-1$
  532. public static final String TAG_PLURALS = "plurals"; //$NON-NLS-1$
  533. public static final String TAG_INTEGER_ARRAY = "integer-array"; //$NON-NLS-1$
  534. public static final String TAG_COLOR = "color"; //$NON-NLS-1$
  535. public static final String TAG_DIMEN = "dimen"; //$NON-NLS-1$
  536. public static final String TAG_DRAWABLE = "drawable"; //$NON-NLS-1$
  537. public static final String TAG_MENU = "menu"; //$NON-NLS-1$
  538. // Tags: Layouts
  539. public static final String VIEW_TAG = "view"; //$NON-NLS-1$
  540. public static final String VIEW_INCLUDE = "include"; //$NON-NLS-1$
  541. public static final String VIEW_MERGE = "merge"; //$NON-NLS-1$
  542. public static final String VIEW_FRAGMENT = "fragment"; //$NON-NLS-1$
  543. public static final String REQUEST_FOCUS = "requestFocus"; //$NON-NLS-1$
  544. public static final String VIEW = "View"; //$NON-NLS-1$
  545. public static final String VIEW_GROUP = "ViewGroup"; //$NON-NLS-1$
  546. public static final String FRAME_LAYOUT = "FrameLayout"; //$NON-NLS-1$
  547. public static final String LINEAR_LAYOUT = "LinearLayout"; //$NON-NLS-1$
  548. public static final String RELATIVE_LAYOUT = "RelativeLayout"; //$NON-NLS-1$
  549. public static final String GRID_LAYOUT = "GridLayout"; //$NON-NLS-1$
  550. public static final String SCROLL_VIEW = "ScrollView"; //$NON-NLS-1$
  551. public static final String BUTTON = "Button"; //$NON-NLS-1$
  552. public static final String COMPOUND_BUTTON = "CompoundButton"; //$NON-NLS-1$
  553. public static final String ADAPTER_VIEW = "AdapterView"; //$NON-NLS-1$
  554. public static final String GALLERY = "Gallery"; //$NON-NLS-1$
  555. public static final String GRID_VIEW = "GridView"; //$NON-NLS-1$
  556. public static final String TAB_HOST = "TabHost"; //$NON-NLS-1$
  557. public static final String RADIO_GROUP = "RadioGroup"; //$NON-NLS-1$
  558. public static final String RADIO_BUTTON = "RadioButton"; //$NON-NLS-1$
  559. public static final String SWITCH = "Switch"; //$NON-NLS-1$
  560. public static final String EDIT_TEXT = "EditText"; //$NON-NLS-1$
  561. public static final String LIST_VIEW = "ListView"; //$NON-NLS-1$
  562. public static final String TEXT_VIEW = "TextView"; //$NON-NLS-1$
  563. public static final String CHECKED_TEXT_VIEW = "CheckedTextView"; //$NON-NLS-1$
  564. public static final String IMAGE_VIEW = "ImageView"; //$NON-NLS-1$
  565. public static final String SURFACE_VIEW = "SurfaceView"; //$NON-NLS-1$
  566. public static final String ABSOLUTE_LAYOUT = "AbsoluteLayout"; //$NON-NLS-1$
  567. public static final String TABLE_LAYOUT = "TableLayout"; //$NON-NLS-1$
  568. public static final String TABLE_ROW = "TableRow"; //$NON-NLS-1$
  569. public static final String TAB_WIDGET = "TabWidget"; //$NON-NLS-1$
  570. public static final String IMAGE_BUTTON = "ImageButton"; //$NON-NLS-1$
  571. public static final String SEEK_BAR = "SeekBar"; //$NON-NLS-1$
  572. public static final String VIEW_STUB = "ViewStub"; //$NON-NLS-1$
  573. public static final String SPINNER = "Spinner"; //$NON-NLS-1$
  574. public static final String WEB_VIEW = "WebView"; //$NON-NLS-1$
  575. public static final String TOGGLE_BUTTON = "ToggleButton"; //$NON-NLS-1$
  576. public static final String CHECK_BOX = "CheckBox"; //$NON-NLS-1$
  577. public static final String ABS_LIST_VIEW = "AbsListView"; //$NON-NLS-1$
  578. public static final String PROGRESS_BAR = "ProgressBar"; //$NON-NLS-1$
  579. public static final String ABS_SPINNER = "AbsSpinner"; //$NON-NLS-1$
  580. public static final String ABS_SEEK_BAR = "AbsSeekBar"; //$NON-NLS-1$
  581. public static final String VIEW_ANIMATOR = "ViewAnimator"; //$NON-NLS-1$
  582. public static final String VIEW_SWITCHER = "ViewSwitcher"; //$NON-NLS-1$
  583. public static final String EXPANDABLE_LIST_VIEW = "ExpandableListView"; //$NON-NLS-1$
  584. public static final String HORIZONTAL_SCROLL_VIEW = "HorizontalScrollView"; //$NON-NLS-1$
  585. public static final String MULTI_AUTO_COMPLETE_TEXT_VIEW = "MultiAutoCompleteTextView"; //$NON-NLS-1$
  586. public static final String AUTO_COMPLETE_TEXT_VIEW = "AutoCompleteTextView"; //$NON-NLS-1$
  587. // Tags: Drawables
  588. public static final String TAG_BITMAP = "bitmap"; //$NON-NLS-1$
  589. // Attributes: Manifest
  590. public static final String ATTR_EXPORTED = "exported"; //$NON-NLS-1$
  591. public static final String ATTR_PERMISSION = "permission"; //$NON-NLS-1$
  592. public static final String ATTR_MIN_SDK_VERSION = "minSdkVersion"; //$NON-NLS-1$
  593. public static final String ATTR_TARGET_SDK_VERSION = "targetSdkVersion"; //$NON-NLS-1$
  594. public static final String ATTR_ICON = "icon"; //$NON-NLS-1$
  595. public static final String ATTR_PACKAGE = "package"; //$NON-NLS-1$
  596. public static final String ATTR_THEME = "theme"; //$NON-NLS-1$
  597. public static final String ATTR_PATH = "path"; //$NON-NLS-1$
  598. public static final String ATTR_PATH_PREFIX = "pathPrefix"; //$NON-NLS-1$
  599. public static final String ATTR_PATH_PATTERN = "pathPattern"; //$NON-NLS-1$
  600. public static final String ATTR_ALLOW_BACKUP = "allowBackup"; //$NON_NLS-1$
  601. public static final String ATTR_DEBUGGABLE = "debuggable"; //$NON-NLS-1$
  602. public static final String ATTR_READ_PERMISSION = "readPermission"; //$NON_NLS-1$
  603. public static final String ATTR_WRITE_PERMISSION = "writePermission"; //$NON_NLS-1$
  604. // Attributes: Resources
  605. public static final String ATTR_NAME = "name"; //$NON-NLS-1$
  606. public static final String ATTR_TYPE = "type"; //$NON-NLS-1$
  607. public static final String ATTR_PARENT = "parent"; //$NON-NLS-1$
  608. public static final String ATTR_TRANSLATABLE = "translatable"; //$NON-NLS-1$
  609. public static final String ATTR_COLOR = "color"; //$NON-NLS-1$
  610. // Attributes: Layout
  611. public static final String ATTR_LAYOUT_RESOURCE_PREFIX = "layout_"; //$NON-NLS-1$
  612. public static final String ATTR_CLASS = "class"; //$NON-NLS-1$
  613. public static final String ATTR_STYLE = "style"; //$NON-NLS-1$
  614. public static final String ATTR_CONTEXT = "context"; //$NON-NLS-1$
  615. public static final String ATTR_ID = "id"; //$NON-NLS-1$
  616. public static final String ATTR_TEXT = "text"; //$NON-NLS-1$
  617. public static final String ATTR_TEXT_SIZE = "textSize"; //$NON-NLS-1$
  618. public static final String ATTR_LABEL = "label"; //$NON-NLS-1$
  619. public static final String ATTR_HINT = "hint"; //$NON-NLS-1$
  620. public static final String ATTR_PROMPT = "prompt"; //$NON-NLS-1$
  621. public static final String ATTR_ON_CLICK = "onClick"; //$NON-NLS-1$
  622. public static final String ATTR_INPUT_TYPE = "inputType"; //$NON-NLS-1$
  623. public static final String ATTR_INPUT_METHOD = "inputMethod"; //$NON-NLS-1$
  624. public static final String ATTR_LAYOUT_GRAVITY = "layout_gravity"; //$NON-NLS-1$
  625. public static final String ATTR_LAYOUT_WIDTH = "layout_width"; //$NON-NLS-1$
  626. public static final String ATTR_LAYOUT_HEIGHT = "layout_height"; //$NON-NLS-1$
  627. public static final String ATTR_LAYOUT_WEIGHT = "layout_weight"; //$NON-NLS-1$
  628. public static final String ATTR_PADDING = "padding"; //$NON-NLS-1$
  629. public static final String ATTR_PADDING_BOTTOM = "paddingBottom"; //$NON-NLS-1$
  630. public static final String ATTR_PADDING_TOP = "paddingTop"; //$NON-NLS-1$
  631. public static final String ATTR_PADDING_RIGHT = "paddingRight"; //$NON-NLS-1$
  632. public static final String ATTR_PADDING_LEFT = "paddingLeft"; //$NON-NLS-1$
  633. public static final String ATTR_FOREGROUND = "foreground"; //$NON-NLS-1$
  634. public static final String ATTR_BACKGROUND = "background"; //$NON-NLS-1$
  635. public static final String ATTR_ORIENTATION = "orientation"; //$NON-NLS-1$
  636. public static final String ATTR_LAYOUT = "layout"; //$NON-NLS-1$
  637. public static final String ATTR_ROW_COUNT = "rowCount"; //$NON-NLS-1$
  638. public static final String ATTR_COLUMN_COUNT = "columnCount"; //$NON-NLS-1$
  639. public static final String ATTR_LABEL_FOR = "labelFor"; //$NON-NLS-1$
  640. public static final String ATTR_BASELINE_ALIGNED = "baselineAligned"; //$NON-NLS-1$
  641. public static final String ATTR_CONTENT_DESCRIPTION = "contentDescription"; //$NON-NLS-1$
  642. public static final String ATTR_IME_ACTION_LABEL = "imeActionLabel"; //$NON-NLS-1$
  643. public static final String ATTR_PRIVATE_IME_OPTIONS = "privateImeOptions"; //$NON-NLS-1$
  644. public static final String VALUE_NONE = "none"; //$NON-NLS-1$
  645. public static final String VALUE_NO = "no"; //$NON-NLS-1$
  646. public static final String ATTR_NUMERIC = "numeric"; //$NON-NLS-1$
  647. public static final String ATTR_IME_ACTION_ID = "imeActionId"; //$NON-NLS-1$
  648. public static final String ATTR_IME_OPTIONS = "imeOptions"; //$NON-NLS-1$
  649. public static final String ATTR_FREEZES_TEXT = "freezesText"; //$NON-NLS-1$
  650. public static final String ATTR_EDITOR_EXTRAS = "editorExtras"; //$NON-NLS-1$
  651. public static final String ATTR_EDITABLE = "editable"; //$NON-NLS-1$
  652. public static final String ATTR_DIGITS = "digits"; //$NON-NLS-1$
  653. public static final String ATTR_CURSOR_VISIBLE = "cursorVisible"; //$NON-NLS-1$
  654. public static final String ATTR_CAPITALIZE = "capitalize"; //$NON-NLS-1$
  655. public static final String ATTR_PHONE_NUMBER = "phoneNumber"; //$NON-NLS-1$
  656. public static final String ATTR_PASSWORD = "password"; //$NON-NLS-1$
  657. public static final String ATTR_BUFFER_TYPE = "bufferType"; //$NON-NLS-1$
  658. public static final String ATTR_AUTO_TEXT = "autoText"; //$NON-NLS-1$
  659. public static final String ATTR_ENABLED = "enabled"; //$NON-NLS-1$
  660. public static final String ATTR_SINGLE_LINE = "singleLine"; //$NON-NLS-1$
  661. public static final String ATTR_SCALE_TYPE = "scaleType"; //$NON-NLS-1$
  662. public static final String ATTR_IMPORTANT_FOR_ACCESSIBILITY =
  663. "importantForAccessibility"; //$NON-NLS-1$
  664. // AbsoluteLayout layout params
  665. public static final String ATTR_LAYOUT_Y = "layout_y"; //$NON-NLS-1$
  666. public static final String ATTR_LAYOUT_X = "layout_x"; //$NON-NLS-1$
  667. // GridLayout layout params
  668. public static final String ATTR_LAYOUT_ROW = "layout_row"; //$NON-NLS-1$
  669. public static final String ATTR_LAYOUT_ROW_SPAN = "layout_rowSpan";//$NON-NLS-1$
  670. public static final String ATTR_LAYOUT_COLUMN = "layout_column"; //$NON-NLS-1$
  671. public static final String ATTR_LAYOUT_COLUMN_SPAN = "layout_columnSpan"; //$NON-NLS-1$
  672. // TableRow
  673. public static final String ATTR_LAYOUT_SPAN = "layout_span"; //$NON-NLS-1$
  674. // RelativeLayout layout params:
  675. public static final String ATTR_LAYOUT_ALIGN_LEFT = "layout_alignLeft"; //$NON-NLS-1$
  676. public static final String ATTR_LAYOUT_ALIGN_RIGHT = "layout_alignRight"; //$NON-NLS-1$
  677. public static final String ATTR_LAYOUT_ALIGN_TOP = "layout_alignTop"; //$NON-NLS-1$
  678. public static final String ATTR_LAYOUT_ALIGN_BOTTOM = "layout_alignBottom"; //$NON-NLS-1$
  679. public static final String ATTR_LAYOUT_ALIGN_PARENT_TOP = "layout_alignParentTop"; //$NON-NLS-1$
  680. public static final String ATTR_LAYOUT_ALIGN_PARENT_BOTTOM = "layout_alignParentBottom"; //$NON-NLS-1$
  681. public static final String ATTR_LAYOUT_ALIGN_PARENT_LEFT = "layout_alignParentLeft";//$NON-NLS-1$
  682. public static final String ATTR_LAYOUT_ALIGN_PARENT_RIGHT = "layout_alignParentRight"; //$NON-NLS-1$
  683. public static final String ATTR_LAYOUT_ALIGN_WITH_PARENT_MISSING = "layout_alignWithParentIfMissing"; //$NON-NLS-1$
  684. public static final String ATTR_LAYOUT_ALIGN_BASELINE = "layout_alignBaseline"; //$NON-NLS-1$
  685. public static final String ATTR_LAYOUT_CENTER_IN_PARENT = "layout_centerInParent"; //$NON-NLS-1$
  686. public static final String ATTR_LAYOUT_CENTER_VERTICAL = "layout_centerVertical"; //$NON-NLS-1$
  687. public static final String ATTR_LAYOUT_CENTER_HORIZONTAL = "layout_centerHorizontal"; //$NON-NLS-1$
  688. public static final String ATTR_LAYOUT_TO_RIGHT_OF = "layout_toRightOf"; //$NON-NLS-1$
  689. public static final String ATTR_LAYOUT_TO_LEFT_OF = "layout_toLeftOf"; //$NON-NLS-1$
  690. public static final String ATTR_LAYOUT_BELOW = "layout_below"; //$NON-NLS-1$
  691. public static final String ATTR_LAYOUT_ABOVE = "layout_above"; //$NON-NLS-1$
  692. // Margins
  693. public static final String ATTR_LAYOUT_MARGIN = "layout_margin"; //$NON-NLS-1$
  694. public static final String ATTR_LAYOUT_MARGIN_LEFT = "layout_marginLeft"; //$NON-NLS-1$
  695. public static final String ATTR_LAYOUT_MARGIN_RIGHT = "layout_marginRight"; //$NON-NLS-1$
  696. public static final String ATTR_LAYOUT_MARGIN_TOP = "layout_marginTop"; //$NON-NLS-1$
  697. public static final String ATTR_LAYOUT_MARGIN_BOTTOM = "layout_marginBottom"; //$NON-NLS-1$
  698. // Attributes: Drawables
  699. public static final String ATTR_TILE_MODE = "tileMode"; //$NON-NLS-1$
  700. // Values: Layouts
  701. public static final String VALUE_FILL_PARENT = "fill_parent"; //$NON-NLS-1$
  702. public static final String VALUE_MATCH_PARENT = "match_parent"; //$NON-NLS-1$
  703. public static final String VALUE_VERTICAL = "vertical"; //$NON-NLS-1$
  704. public static final String VALUE_TRUE = "true"; //$NON-NLS-1$
  705. public static final String VALUE_EDITABLE = "editable"; //$NON-NLS-1$
  706. // Values: Resources
  707. public static final String VALUE_ID = "id"; //$NON-NLS-1$
  708. // Values: Drawables
  709. public static final String VALUE_DISABLED = "disabled"; //$NON-NLS-1$
  710. public static final String VALUE_CLAMP = "clamp"; //$NON-NLS-1$
  711. // Menus
  712. public static final String ATTR_SHOW_AS_ACTION = "showAsAction"; //$NON-NLS-1$
  713. public static final String VALUE_IF_ROOM = "ifRoom"; //$NON-NLS-1$
  714. public static final String VALUE_ALWAYS = "always"; //$NON-NLS-1$
  715. // Units
  716. public static final String UNIT_DP = "dp"; //$NON-NLS-1$
  717. public static final String UNIT_DIP = "dip"; //$NON-NLS-1$
  718. public static final String UNIT_SP = "sp"; //$NON-NLS-1$
  719. public static final String UNIT_PX = "px"; //$NON-NLS-1$
  720. public static final String UNIT_IN = "in"; //$NON-NLS-1$
  721. public static final String UNIT_MM = "mm"; //$NON-NLS-1$
  722. public static final String UNIT_PT = "pt"; /

Large files files are truncated, but you can click here to view the full file