the <wocompile> tag should take an if attribute
-----------------------------------------------
Key: WOL-1100
URL: http://issues.objectstyle.org/jira/browse/WOL-1100
Project: WOProject/WOLips
Issue Type: Bug
Components: WOLips General
Environment: WOLips rev 5693
Reporter: Ray Kiddy
Here is all that is needed to allow the if attribute to be used with the <wocompile> tag.
This would enable, for example, smarter processing of test sources.
% svn diff woproject/woproject-ant-tasks/src/java/org/objectstyle/woproject/ant/WOCompile.java
Index: woproject/woproject-ant-tasks/src/java/org/objectstyle/woproject/ant/WOCompile.java
===================================================================
--- woproject/woproject-ant-tasks/src/java/org/objectstyle/woproject/ant/WOCompile.java (revision 5693)
+++ woproject/woproject-ant-tasks/src/java/org/objectstyle/woproject/ant/WOCompile.java (working copy)
..-84,12 +84,20 @@
this.dumpClasspath = dumpClasspath;
}
+ private String ifProperty;
+
+ public void setIf(String ifProperty) {
+ this.ifProperty = ifProperty;
+ }
+
..verride
public void execute() throws BuildException {
- setClasspath(FrameworkSet.jarsPathForFrameworkSets(getProject(), frameworkSets, new WOEnvironment(getProject().getProperties()).getWOVariables()));
- if (dumpClasspath != null) {
- getProject().setProperty(dumpClasspath, getClasspath().toString());
+ if ((ifProperty == null) || (getProject().getProperty(ifProperty) != null)) {
+ setClasspath(FrameworkSet.jarsPathForFrameworkSets(getProject(), frameworkSets, new WOEnvironment(getProject().getProperties()).getWOVariables()));
+ if (dumpClasspath != null) {
+ getProject().setProperty(dumpClasspath, getClasspath().toString());
+ }
+ super.execute();
}
- super.execute();
}
}
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.objectstyle.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
This archive was generated by hypermail 2.0.0 : Sat Sep 19 2009 - 18:18:54 EDT