| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><HTML> |
| <HEAD> |
| <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"> |
| <META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> |
| |
| <LINK REL="STYLESHEET" HREF="../book.css" CHARSET="ISO-8859-1" TYPE="text/css"> |
| <title>Builds</title> |
| |
| </HEAD> |
| <BODY BGCOLOR="#ffffff"> |
| |
| <h1 class="Head">Builds</h1> |
| <p class="Para">Builders create or modify workspace resources, |
| usually based on the existence and state of other resources. They are a powerful |
| mechanism for enforcing the constraints of some domain. For example, a Java |
| builder converts Java source files (.java files) into executable class files |
| (.class files), a web link builder updates links to files whose name/location |
| have changed, etc. As resources are created and modified, builders are run |
| and the constraints are maintained. This transform need not be one to one. For |
| example, a single .java file can produce several .class files. </p> |
| <h2>Auto-build vs. Manual Build</h2> |
| <p class="Intro">There are two distinct user work modes with respect to |
| building: relying on Auto-build, or user initiated manual building. |
| <p class="Intro">Users who do not need fine-grained control over when builds |
| occur may simply choose to turn on auto-building. With auto-building on, |
| builds occur after every set of resource changes (e.g., saving a file, importing |
| a ZIP, ...). Auto-building is efficient because the amount of work done is |
| proportional to the amount of change done. The benefit of auto-building is |
| that your derived resources (e.g., Java .class files) are always up to date. |
| Auto-building is turned on/off via the <i>Perform build automatically on |
| resource modification</i> option on the Window > Preferences > Workbench |
| page. |
| <p class="Intro">Users needing more control over when builds occur can turn off |
| auto-building and manually invoke builds. This is sometimes desirable in |
| cases where,for example, you know building is of no value until you finish a |
| large set of changes. In this case there is no benefit to paying the cost of |
| auto-building. Builds can be invoked manually in numerous ways, for example, by |
| selecting Rebuild All from a project's context menu. |
| <p class="Intro">The disadvantage of manual building is that the tasks which |
| were generated to indicate build errors quickly become out of date until you |
| build. In addition, it is very important that you remember to manually build |
| before relying on build output (e.g. before running your Java program). |
| <h2>Full vs. Incremental Builds</h2> |
| <p class="Intro">There are two kinds of builds: full and incremental. An |
| incremental build works with a previous built state and applies the transforms |
| of the configured builders only on the resources which have changed since that |
| previous state was computed (i.e., since the last build). Auto-building |
| uses incremental building for efficiency. |
| <p class="Intro">A full build (a.k.a. <i>rebuild</i>) discards any existing |
| built state and transforms all requested resources according the domain rules of |
| the configured builders. The first incremental build is equivalent to a |
| full build as there is no previous state to work from. |
| <p class="Intro">Depending on the user's needs, full and incremental builds can |
| be done over a specific set of projects or the workspace as a whole. Specific |
| files and folders cannot be built.</p> |
| |
| <p> <br> |
| <a href="../hglegal2003.htm"><img src="../images/ngibmcpy2003.gif" alt="Copyright IBM Corporation and others 2000, 2003" border="0" width="324" height="14"></a> |
| </p> |
| |
| </BODY> |
| </HTML> |