Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ForwardAction

 
John Eric Hamacher
Ranch Hand
Posts: 230
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello, I am having a frustrating problem trying to compile my code against Struts 1.3.8. I didn't know where to post this issue, in Build tools or Struts. The code below compiles in Jdeveloper but not with mvn compile:

package com.enetrix.sis.util;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.actions.ForwardAction;

public class RedirectAction extends ForwardAction {

public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception {
ActionForward forward = super.execute (mapping, form, request, response);
forward.setRedirect(true);
return forward;
}
}

Maven gives me "package org.apache.struts.actions does not exist" even though my pom specifies:

<dependency>
<groupId>org.apache.struts</groupId>
<artifactId>struts-core</artifactId>
<version>1.3.8</version>
<scope>compile</scope>
</dependency>

Anybody have any ideas?

eric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic