You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by pl...@apache.org on 2006/04/24 07:01:11 UTC
svn commit: r396426 - in /incubator/webwork2: ./ action/
action/src/main/java/org/apache/struts/action2/quickstart/ webapps/showcase/
Author: plightbo
Date: Sun Apr 23 22:01:09 2006
New Revision: 396426
URL: http://svn.apache.org/viewcvs?rev=396426&view=rev
Log:
quick start runs from idea once again
Modified:
incubator/webwork2/action/pom.xml
incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/Configuration.java
incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/MultiWebApplicationContext.java
incubator/webwork2/pom.xml
incubator/webwork2/webapps/showcase/quickstart.xml
Modified: incubator/webwork2/action/pom.xml
URL: http://svn.apache.org/viewcvs/incubator/webwork2/action/pom.xml?rev=396426&r1=396425&r2=396426&view=diff
==============================================================================
--- incubator/webwork2/action/pom.xml (original)
+++ incubator/webwork2/action/pom.xml Sun Apr 23 22:01:09 2006
@@ -116,6 +116,76 @@
<optional>true</optional>
</dependency>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ <version>1.6.5</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-compiler</artifactId>
+ <version>5.5.12</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-runtime</artifactId>
+ <version>5.5.12</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-compiler-jdt</artifactId>
+ <version>5.5.12</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-el</groupId>
+ <artifactId>commons-el</artifactId>
+ <version>1.0</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>1.0</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.1</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>jspapi</groupId>
+ <artifactId>jsp-api</artifactId>
+ <version>2.0</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <version>2.1.1</version>
+ <optional>true</optional>
+ </dependency>
+
+ <dependency>
+ <groupId>xstream</groupId>
+ <artifactId>xstream</artifactId>
+ <version>1.1.2</version>
+ <optional>true</optional>
+ </dependency>
+
<!-- Jasper -->
<dependency>
<groupId>jasperreports</groupId>
Modified: incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/Configuration.java
URL: http://svn.apache.org/viewcvs/incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/Configuration.java?rev=396426&r1=396425&r2=396426&view=diff
==============================================================================
--- incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/Configuration.java (original)
+++ incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/Configuration.java Sun Apr 23 22:01:09 2006
@@ -35,9 +35,9 @@
* Configuration for the QuickStart program.
*/
public class Configuration implements Serializable {
-
+
private static final long serialVersionUID = 9159115401614443449L;
-
+
String ideaConfig;
String extendsConfig;
String resolver;
@@ -132,32 +132,36 @@
public void resolveDirs(String wd) {
if (ideaConfig != null) {
- String full = resolveDir(this.ideaConfig, wd);
-
- try {
- DocumentBuilder db = DocumentBuilderFactory.newInstance().newDocumentBuilder();
- Document doc = db.parse(full);
- NodeList components = doc.getElementsByTagName("root");
- List jars = new ArrayList();
- for (int i = 0; i < components.getLength(); i++) {
- Element e = (Element) components.item(i);
- String value = e.getAttribute("url");
- if (value != null && value.startsWith("jar://") && value.endsWith(".jar!/")) {
- value = value.substring(6, value.length() - 2);
- if (value.startsWith("$MODULE_DIR$")) {
- value = value.substring(13);
+ String[] parts = ideaConfig.split(",");
+ for (int i = 0; i < parts.length; i++) {
+ String full = resolveDir(parts[i], wd);
+
+ try {
+ DocumentBuilder db = DocumentBuilderFactory.newInstance().newDocumentBuilder();
+ Document doc = db.parse(full);
+ NodeList components = doc.getElementsByTagName("root");
+ List jars = new ArrayList();
+ for (int j = 0; j < components.getLength(); j++) {
+ Element e = (Element) components.item(j);
+ String value = e.getAttribute("url");
+ if (value != null && value.startsWith("jar://") && value.endsWith(".jar!/")) {
+ value = value.substring(6, value.length() - 2);
+ if (value.startsWith("$MODULE_DIR$")) {
+ value = value.substring(13);
+ }
+ jars.add(value);
}
- jars.add(value);
}
- }
- if (this.libs != null) {
- this.libs.addAll(jars);
- } else {
- this.libs = jars;
+ if (this.libs != null) {
+ this.libs.addAll(jars);
+ } else {
+ this.libs = jars;
+ }
+ } catch (Exception e) {
+ e.printStackTrace();
}
- } catch (Exception e) {
- e.printStackTrace();
+
}
}
resolve(this.libs, wd);
Modified: incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/MultiWebApplicationContext.java
URL: http://svn.apache.org/viewcvs/incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/MultiWebApplicationContext.java?rev=396426&r1=396425&r2=396426&view=diff
==============================================================================
--- incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/MultiWebApplicationContext.java (original)
+++ incubator/webwork2/action/src/main/java/org/apache/struts/action2/quickstart/MultiWebApplicationContext.java Sun Apr 23 22:01:09 2006
@@ -85,12 +85,12 @@
// still haven't found what we're looking for?
// Alright, let's just hack this to work in IDEA
- if (uriInContext.equals("/struts")) {
+ if (uriInContext.equals("/struts-action")) {
// we do this check to support both "quickstart:showcase" and "quickstart" (using quickstart.xml)
- if (new File("../../src/java/META-INF/taglib.tld").exists()) {
- return FileResource.newResource("../../src/java/META-INF/taglib.tld");
+ if (new File("../../action/src/main/resources/META-INF/taglib.tld").exists()) {
+ return FileResource.newResource("../../action/src/main/resources/META-INF/taglib.tld");
} else {
- return FileResource.newResource("src/java/META-INF/taglib.tld");
+ return FileResource.newResource("src/main/resources/META-INF/taglib.tld");
}
}
Modified: incubator/webwork2/pom.xml
URL: http://svn.apache.org/viewcvs/incubator/webwork2/pom.xml?rev=396426&r1=396425&r2=396426&view=diff
==============================================================================
--- incubator/webwork2/pom.xml (original)
+++ incubator/webwork2/pom.xml Sun Apr 23 22:01:09 2006
@@ -297,6 +297,66 @@
<version>3.1.0</version>
</dependency>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ <version>1.6.5</version>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-runtime</artifactId>
+ <version>5.5.12</version>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-compiler</artifactId>
+ <version>5.5.12</version>
+ </dependency>
+
+ <dependency>
+ <groupId>tomcat</groupId>
+ <artifactId>jasper-compiler-jdt</artifactId>
+ <version>5.5.12</version>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-el</groupId>
+ <artifactId>commons-el</artifactId>
+ <version>1.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>1.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>jspapi</groupId>
+ <artifactId>jsp-api</artifactId>
+ <version>2.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <version>2.1.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>xstream</groupId>
+ <artifactId>xstream</artifactId>
+ <version>1.1.2</version>
+ </dependency>
+
<!-- Tiles -->
<dependency>
<groupId>org.apache.struts.tiles</groupId>
Modified: incubator/webwork2/webapps/showcase/quickstart.xml
URL: http://svn.apache.org/viewcvs/incubator/webwork2/webapps/showcase/quickstart.xml?rev=396426&r1=396425&r2=396426&view=diff
==============================================================================
--- incubator/webwork2/webapps/showcase/quickstart.xml (original)
+++ incubator/webwork2/webapps/showcase/quickstart.xml Sun Apr 23 22:01:09 2006
@@ -12,7 +12,7 @@
users who don't have a single directory in their project that
contains all the libraries they need.
-->
- <!--<ideaConfig>ShowCase.iml</ideaConfig>-->
+ <ideaConfig>../../action/action.iml,../../thirdparty/jasperreports/action-jasperreports.iml,webapp-showcase.iml</ideaConfig>
<!-- The context in which to deploy the web application -->
<context>/showcase</context>
@@ -37,14 +37,16 @@
using the classDirs and libs elements
-->
<sources>
- <dir>src/java</dir>
+ <dir>src/main/java</dir>
</sources>
<!--
The classDirs directories can be a jar or a directory of classes
-->
<classDirs>
- <dir>src/webapp/WEB-INF/classes</dir>
+ <dir>src/main/webapp/WEB-INF/classes</dir>
+ <dir>../../thirdparty/jasperreports/target/classes</dir>
+ <dir>../../action/target/classes</dir>
</classDirs>
<!--
@@ -56,7 +58,7 @@
<webDirs>
<webDir>
<path>/</path>
- <dir>src/webapp</dir>
+ <dir>src/main/webapp</dir>
</webDir>
</webDirs>
</configuration>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org