You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

MagicNames.java 9.8 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325
  1. /*
  2. * Licensed to the Apache Software Foundation (ASF) under one or more
  3. * contributor license agreements. See the NOTICE file distributed with
  4. * this work for additional information regarding copyright ownership.
  5. * The ASF licenses this file to You under the Apache License, Version 2.0
  6. * (the "License"); you may not use this file except in compliance with
  7. * the License. You may obtain a copy of the License at
  8. *
  9. * http://www.apache.org/licenses/LICENSE-2.0
  10. *
  11. * Unless required by applicable law or agreed to in writing, software
  12. * distributed under the License is distributed on an "AS IS" BASIS,
  13. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. * See the License for the specific language governing permissions and
  15. * limitations under the License.
  16. *
  17. */
  18. package org.apache.tools.ant;
  19. import org.apache.tools.ant.launch.Launcher;
  20. /**
  21. * Magic names used within Ant.
  22. *
  23. * Not all magic names are here yet.
  24. *
  25. * @since Ant 1.6
  26. */
  27. public final class MagicNames {
  28. private MagicNames() {
  29. }
  30. /**
  31. * prefix for antlib URIs:
  32. * {@value}
  33. */
  34. public static final String ANTLIB_PREFIX = "antlib:";
  35. /**
  36. * Ant version property.
  37. * Value: {@value}
  38. */
  39. public static final String ANT_VERSION = "ant.version";
  40. /**
  41. * System classpath policy.
  42. * Value: {@value}
  43. */
  44. public static final String BUILD_SYSCLASSPATH = "build.sysclasspath";
  45. /**
  46. * The name of the script repository used by the script repo task.
  47. * Value {@value}
  48. */
  49. public static final String SCRIPT_REPOSITORY = "org.apache.ant.scriptrepo";
  50. /**
  51. * The name of the script cache used by the script runner.
  52. * Value {@value}
  53. */
  54. public static final String SCRIPT_CACHE = "org.apache.ant.scriptcache";
  55. /**
  56. * The name of the reference to the System Class Loader.
  57. * Value {@value}
  58. **/
  59. public static final String SYSTEM_LOADER_REF = "ant.coreLoader";
  60. /**
  61. * Name of the property which can provide an override of the repository dir.
  62. * for the libraries task
  63. * Value {@value}
  64. */
  65. public static final String REPOSITORY_DIR_PROPERTY = "ant.maven.repository.dir";
  66. /**
  67. * Name of the property which can provide an override of the repository URL.
  68. * for the libraries task
  69. * Value {@value}
  70. */
  71. public static final String REPOSITORY_URL_PROPERTY = "ant.maven.repository.url";
  72. /**
  73. * name of the resource that taskdefs are stored under.
  74. * Value: {@value}
  75. */
  76. public static final String TASKDEF_PROPERTIES_RESOURCE =
  77. "/org/apache/tools/ant/taskdefs/defaults.properties";
  78. /**
  79. * name of the resource that typedefs are stored under.
  80. * Value: {@value}
  81. */
  82. public static final String TYPEDEFS_PROPERTIES_RESOURCE =
  83. "/org/apache/tools/ant/types/defaults.properties";
  84. /**
  85. * Reference to the current Ant executor.
  86. * Value: {@value}
  87. */
  88. public static final String ANT_EXECUTOR_REFERENCE = "ant.executor";
  89. /**
  90. * Property defining the classname of an executor.
  91. * Value: {@value}
  92. */
  93. public static final String ANT_EXECUTOR_CLASSNAME = "ant.executor.class";
  94. /**
  95. * property name for basedir of the project.
  96. * Value: {@value}
  97. */
  98. public static final String PROJECT_BASEDIR = "basedir";
  99. /**
  100. * property for ant file name.
  101. * Value: {@value}
  102. */
  103. public static final String ANT_FILE = "ant.file";
  104. /**
  105. * property for type of ant build file (either file or url)
  106. * Value: {@value}
  107. * @since Ant 1.8.0
  108. */
  109. public static final String ANT_FILE_TYPE = "ant.file.type";
  110. /**
  111. * ant build file of type file
  112. * Value: {@value}
  113. * @since Ant 1.8.0
  114. */
  115. public static final String ANT_FILE_TYPE_FILE = "file";
  116. /**
  117. * ant build file of type url
  118. * Value: {@value}
  119. * @since Ant 1.8.0
  120. */
  121. public static final String ANT_FILE_TYPE_URL = "url";
  122. /**
  123. * Property used to store the java version ant is running in.
  124. * Value: {@value}
  125. * @since Ant 1.7
  126. */
  127. public static final String ANT_JAVA_VERSION = "ant.java.version";
  128. /**
  129. * Property used to store the location of ant.
  130. * Value: {@value}
  131. * @since Ant 1.7
  132. */
  133. public static final String ANT_HOME = Launcher.ANTHOME_PROPERTY;
  134. /**
  135. * Property used to store the location of the ant library (typically the ant.jar file.)
  136. * Value: {@value}
  137. * @since Ant 1.7
  138. */
  139. public static final String ANT_LIB = "ant.core.lib";
  140. /**
  141. * property for regular expression implementation.
  142. * Value: {@value}
  143. */
  144. public static final String REGEXP_IMPL = "ant.regexp.regexpimpl";
  145. /**
  146. * property that provides the default value for javac's and
  147. * javadoc's source attribute.
  148. * Value: {@value}
  149. * @since Ant 1.7
  150. */
  151. public static final String BUILD_JAVAC_SOURCE = "ant.build.javac.source";
  152. /**
  153. * property that provides the default value for javac's target attribute.
  154. * Value: {@value}
  155. * @since Ant 1.7
  156. */
  157. public static final String BUILD_JAVAC_TARGET = "ant.build.javac.target";
  158. /**
  159. * Name of the magic property that controls classloader reuse.
  160. * Value: {@value}
  161. * @since Ant 1.4.
  162. */
  163. public static final String REFID_CLASSPATH_REUSE_LOADER = "ant.reuse.loader";
  164. /**
  165. * Prefix used to store classloader references.
  166. * Value: {@value}
  167. */
  168. public static final String REFID_CLASSPATH_LOADER_PREFIX = "ant.loader.";
  169. /**
  170. * Reference used to store the property helper.
  171. * Value: {@value}
  172. */
  173. public static final String REFID_PROPERTY_HELPER = "ant.PropertyHelper";
  174. /**
  175. * Reference used to store the local properties.
  176. * Value: {@value}
  177. */
  178. public static final String REFID_LOCAL_PROPERTIES = "ant.LocalProperties";
  179. /**
  180. * Name of JVM system property which provides the name of the ProjectHelper class to use.
  181. * Value: {@value}
  182. */
  183. public static final String PROJECT_HELPER_CLASS = "org.apache.tools.ant.ProjectHelper";
  184. /**
  185. * The service identifier in jars which provide ProjectHelper implementations.
  186. * Value: {@value}
  187. */
  188. public static final String PROJECT_HELPER_SERVICE =
  189. "META-INF/services/org.apache.tools.ant.ProjectHelper";
  190. /**
  191. * Name of ProjectHelper reference that we add to a project.
  192. * Value: {@value}
  193. */
  194. public static final String REFID_PROJECT_HELPER = "ant.projectHelper";
  195. /**
  196. * Name of the property holding the name of the currently
  197. * executing project, if one has been specified.
  198. *
  199. * Value: {@value}
  200. * @since Ant 1.8.0
  201. */
  202. public static final String PROJECT_NAME = "ant.project.name";
  203. /**
  204. * Name of the property holding the default target of the
  205. * currently executing project, if one has been specified.
  206. *
  207. * Value: {@value}
  208. * @since Ant 1.8.0
  209. */
  210. public static final String PROJECT_DEFAULT_TARGET
  211. = "ant.project.default-target";
  212. /**
  213. * Name of the property holding a comma separated list of targets
  214. * that have been invoked (from the command line).
  215. *
  216. * Value: {@value}
  217. * @since Ant 1.8.0
  218. */
  219. public static final String PROJECT_INVOKED_TARGETS
  220. = "ant.project.invoked-targets";
  221. /**
  222. * Name of the project reference holding an instance of {@link
  223. * org.apache.tools.ant.taskdefs.launcher.CommandLauncher} to use
  224. * when executing commands with the help of an external script.
  225. *
  226. * <p>Alternatively this is the name of a system property holding
  227. * the fully qualified class name of a {@link
  228. * org.apache.tools.ant.taskdefs.launcher.CommandLauncher}.</p>
  229. *
  230. * Value: {@value}
  231. * @since Ant 1.9.0
  232. */
  233. public static final String ANT_SHELL_LAUNCHER_REF_ID = "ant.shellLauncher";
  234. /**
  235. * Name of the project reference holding an instance of {@link
  236. * org.apache.tools.ant.taskdefs.launcher.CommandLauncher} to use
  237. * when executing commands without the help of an external script.
  238. *
  239. * <p>Alternatively this is the name of a system property holding
  240. * the fully qualified class name of a {@link
  241. * org.apache.tools.ant.taskdefs.launcher.CommandLauncher}.</p>
  242. *
  243. * Value: {@value}
  244. * @since Ant 1.9.0
  245. */
  246. public static final String ANT_VM_LAUNCHER_REF_ID = "ant.vmLauncher";
  247. /**
  248. * Name of the namespace "type".
  249. * (Note: cannot be used as an element.)
  250. * @since Ant 1.9.1
  251. */
  252. public static final String ATTRIBUTE_NAMESPACE = "attribute namespace";
  253. /**
  254. * Name of the property which can provide an override of the
  255. * User-Agent used in &lt;get&gt; tasks.
  256. * Value {@value}
  257. */
  258. public static final String HTTP_AGENT_PROPERTY = "ant.http.agent";
  259. /**
  260. * Magic property that can be set to contain a value for tstamp's
  261. * "now" in order to make builds that use the task create
  262. * reproducible results.
  263. *
  264. * <p>The value is expected to be a number representing the date
  265. * as seconds since the epoch.</p>
  266. *
  267. * Value: {@value}
  268. * @since Ant 1.10.2
  269. */
  270. public static final String TSTAMP_NOW = "ant.tstamp.now";
  271. /**
  272. * Magic property that can be set to contain a value for tstamp's
  273. * "now" in order to make builds that use the task create
  274. * reproducible results.
  275. *
  276. * <p>The value is expected to be in ISO time format
  277. * (<i>1972-04-17T08:07</i>)</p>
  278. *
  279. * Value: {@value}
  280. * @since Ant 1.10.2
  281. */
  282. public static final String TSTAMP_NOW_ISO = "ant.tstamp.now.iso";
  283. }