diff --git a/docs/manual/CoreTasks/libraries.html b/docs/manual/CoreTasks/libraries.html new file mode 100644 index 000000000..e884ee074 --- /dev/null +++ b/docs/manual/CoreTasks/libraries.html @@ -0,0 +1,391 @@ + + + + +Libraries Task + + + + +

Libraries

+

Description

+

+ + Extensible library download mechanism, integrated with the + Maven repository hosted + at ibiblio.org. + +

+ +

+ This task can: +

+
    +
  1. Download publicly published JAR files by version.
  2. +
  3. Download JAR files from private file: or http: repositories
  4. +
  5. Cache the JAR files in a directory tree
  6. +
  7. Check for updates on a regular schedule
  8. +
  9. Build paths for compilation/execution.
  10. +
  11. Fail the build if needed libraries are missing
  12. +
  13. Force an update of all libraries
  14. +
  15. Skip all downloading when offline +
+ +

Parameters

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
destDirDestination directory for all downloads + Yes
offlineFlag to indicate that the system is offline, and that + no downloads should take place. + No
flattenflag to indicate that files should be flattened when downloaded + No -default false
pathIDName of a path to create containing all + libraries in this declaration. + No
repositoryRefReference to a predefined repository + Only if no repository is defined inline
+ + + +

Nested Elements

+ + +

library

+This is the core of the system; a library to (potentially) download. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
projectName of the project + Yes
version + Yes
archiveName of the archive + No
destinationNameFilename of downloaded file + No, default remote name
suffixSuffix of the archive + No -default ".jar"
enabledflag to turn on or off specific download/use + of an archive + No -default "true"
+ +

Repository

+ +A repository is Ant datatype that extends the Repository type. +Ant only ships with one: the mavenrepository; + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
urlURL of the repository + No
+ No
+ +

Example:

+
+    <repository ref="predefined.repository" />
+
+ +

mavenrepository

+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
urlURL of the repository + No
checkMD5Flag to turn on MD5 checking + (unimplemented) + No
usernameHTTP authentication username + No
passwordHTTP authentication password + Only if username is set
+ +

UpdatePolicies

+ +

Update policies are an (extensible) means of tuning the download, running +code before and possibly after a download. They can enable or disable +checks for individual files, skip the download process, or perform some +post-download validation. +

+ +

All policies have at least the common set of attributes; some may have more, +in which case an updated attribute list is shown.

+ + + + + + + + + + + + +
AttributeDescriptionRequired
enabledEnabled flag + No -default "true"
+ +

Policies can be chained by listing them in order. Before an update/download +takes place, all policies will be executed in order. After the download, the +policies will be invoked in reverse order. The compound policy in such a +situation is left to the experimentor, though reading the source will help. +

+ +

+Developers may add new polices (such +as signing incoming files) by adding new datatypes extending the +LibraryPolicy class.

+ +

noupdate

+ +

This policy will disable remote downloads when enabled. It is the policy +equivalent of the offline flag.

+ + +

Example:

+
+    <noupdate  />
+
+ +

forceupdate

+ +

This policy forces all libraries to be downloaded. If any download failed, +the build will halt.

+

Example:

+
+    <forceupdate  />
+
+ +

timestamp

+ +

This policy tells Ant to check the repository to see if the files have changed +using timestamp checks. Any files which are up to date will not be downloaded again.

+ +

Example:

+
+    <timestamp  />
+
+ +

scheduledupdate

+ +This policy tells Ant to check the repository to see if the files have changed, +but only intermittently. An interval of the size of the schedule has to have +passed, or the set of files to check has to have changed. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
enabledEnabled flag + No -default "true"
markerFileName of a file to cache download history + Yes
Daysnumber of days between update checks + No
Hoursnumber of hours between update checks + No
Minutesnumber of minutes between update checks + No
+ +

Example:

+
+    <scheduledupdate days="1" hours="3" minutes="17"  />
+
+ +

Check for an update every 27 hours, 17 minutes.

+ + +

assertdownloaded

+ +

This policy is really for testing the library. It does not +alter the download policy, but after any download has taken place, +it verifies that the number of files downloaded matches the number +expected.

+ + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
countnumber of downloaded files expected. + Yes
enabledEnabled flag + No -default "true"
+ +

Example:

+
+    <assertdownloaded cound="4"  />
+
+ +

Examples

+
+    <!--
+    versions.properties says
+    xdoclet.version=2.0
+    commons-logging.version=1.0.3
+    commons-collections.version=3.1
+    -->
+    <property file="versions.properties" />
+    
+    <libraries destDir="${lib.dir}" pathid="xdoclet.lib" >
+      <mavenrepository />
+      <library project="xdoclet" 
+        version="${xdoclet.version}" />
+      <library project="commons-logging"  
+        version="${commons-logging.version}" />
+      <library project="commons-collections"  
+        version="${commons-collections.version}" />
+    </libraries>
+
+ +

Load in versions from a file, then download the relevant archives. No +update schedule is defined, but a path is created for insertion into a +classpath. This property file driven dependency model is what we recommend +over hard coding versions in a build file. +

+
   <libraries destDir="build/lib" offline="${offline}" flatten="true">
+      <mavenrepository url="${private.server}"/>
+      <library project="doomed" archive="dead-code"
+        suffix=".war"
+        destinationName="product.war"
+        version="LATEST" 
+        />
+      <scheduledupdate markerfile="build/lib/marker.properties"
+        hours="11" />
+    </libraries>
+
+ +

Download doomed/dead-code.LATEST.war from a private repository, save it to +build/lib/product.war with an update schedule of every eleven hours. +

+ +

Copyright © 2005 The Apache Software Foundation. All rights +Reserved.

+ + + + diff --git a/docs/manual/CoreTasks/nice.html b/docs/manual/CoreTasks/nice.html index 4403b089a..7c871d32a 100644 --- a/docs/manual/CoreTasks/nice.html +++ b/docs/manual/CoreTasks/nice.html @@ -36,19 +36,19 @@

Examples

   <nice newpriority="10"/>
-Set the Thread priority to 10. +Set the Thread priority to 10 (highest).
   <nice currentpriority="priority"/>
Store the current Thread priority in the user property "priority".
    <nice currentpriority="currentpriority" newpriority="1"/>
 
-

Set the current Thread priority to 1, storing the original +

Set the current Thread priority to 1 (lowest), storing the original priority in the user property "currentpriority". This can be used to set the priority back to its original value later.


-

Copyright © 2004 The Apache Software Foundation. All rights +

Copyright © 2004-2005 The Apache Software Foundation. All rights Reserved.

diff --git a/docs/manual/api/index.html b/docs/manual/api/index.html index 7eab05e23..32cee1d7c 100644 --- a/docs/manual/api/index.html +++ b/docs/manual/api/index.html @@ -1,11 +1,37 @@ - - - -Apache Ant API - - -Redirecting to Apache Ant API ... - - - + + + + + + +Apache Ant API + + + + + + + + + + + +<H2> +Frame Alert</H2> +<P> +This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. +<BR> +Link to<A HREF="overview-summary.html">Non-frame version.</A> + + + diff --git a/docs/manual/coretasklist.html b/docs/manual/coretasklist.html index 73067931a..192362201 100644 --- a/docs/manual/coretasklist.html +++ b/docs/manual/coretasklist.html @@ -61,6 +61,7 @@ Javac
Javadoc/Javadoc2
Length
+Libraries
LoadFile
LoadProperties
Mail