mirror of
https://github.com/apache/struts.git
synced 2026-08-11 01:27:14 +00:00
WW-1453
Simple cleanup items - remove duplicate and/or unused imports - change static access to class, not instance git-svn-id: https://svn.apache.org/repos/asf/struts/struts2/trunk@454565 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -26,7 +26,6 @@ import com.opensymphony.xwork2.util.ClassLoaderUtil;
|
||||
import com.opensymphony.xwork2.ObjectFactory;
|
||||
import com.opensymphony.xwork2.util.OgnlUtil;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* <!-- START SNIPPET: javadoc -->
|
||||
|
||||
@@ -39,7 +39,6 @@ import org.apache.struts2.views.util.UrlHelper;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.TextParseUtil;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* Base class to extend for UI components.
|
||||
|
||||
@@ -31,7 +31,6 @@ import org.apache.commons.logging.LogFactory;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.TextProvider;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* <!-- START SNIPPET: javadoc -->
|
||||
|
||||
@@ -13,7 +13,6 @@ import org.apache.struts2.StrutsException;
|
||||
|
||||
import com.opensymphony.xwork2.util.OgnlUtil;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* <!-- START SNIPPET: javadoc -->
|
||||
|
||||
@@ -23,7 +23,6 @@ import java.util.Iterator;
|
||||
import org.apache.struts2.util.MakeIterator;
|
||||
import org.apache.struts2.views.jsp.IteratorStatus;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
|
||||
@@ -19,7 +19,6 @@ package org.apache.struts2.components;
|
||||
|
||||
import java.io.Writer;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
|
||||
@@ -19,7 +19,6 @@ package org.apache.struts2.components;
|
||||
|
||||
import java.io.Writer;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
|
||||
@@ -30,7 +30,6 @@ import org.apache.commons.logging.LogFactory;
|
||||
import com.opensymphony.xwork2.util.TextUtils;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.TextProvider;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* <!-- START SNIPPET: javadoc -->
|
||||
|
||||
@@ -4,10 +4,7 @@
|
||||
package org.apache.struts2.config;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URL;
|
||||
import java.util.ArrayList;
|
||||
@@ -18,7 +15,6 @@ import java.util.Map;
|
||||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.struts2.StrutsException;
|
||||
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.config.providers.XmlConfigurationProvider;
|
||||
|
||||
@@ -51,7 +51,6 @@ import org.apache.struts2.dispatcher.mapper.ActionMapping;
|
||||
|
||||
import com.opensymphony.xwork2.util.ClassLoaderUtil;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.XWorkException;
|
||||
|
||||
/**
|
||||
* Master filter for Struts that handles four distinct
|
||||
@@ -221,7 +220,7 @@ public class FilterDispatcher implements Filter, StrutsStatics {
|
||||
mapper = ActionMapperFactory.getMapper();
|
||||
mapping = mapper.getMapping(request, du.getConfigurationManager());
|
||||
} catch (Exception ex) {
|
||||
du.sendError(request, response, servletContext, response.SC_INTERNAL_SERVER_ERROR, ex);
|
||||
du.sendError(request, response, servletContext, HttpServletResponse.SC_INTERNAL_SERVER_ERROR, ex);
|
||||
ActionContextCleanUp.cleanUp(req);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -24,7 +24,6 @@ import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.struts2.ServletActionContext;
|
||||
import org.apache.struts2.dispatcher.mapper.ActionMapperFactory;
|
||||
import org.springframework.beans.factory.config.SetFactoryBean;
|
||||
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
|
||||
@@ -19,11 +19,9 @@ package org.apache.struts2.dispatcher;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.AbstractMap;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Enumeration;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
|
||||
@@ -41,7 +41,6 @@ import org.apache.velocity.context.Context;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -29,7 +29,6 @@ import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.Result;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -61,7 +61,6 @@ import com.opensymphony.xwork2.ActionProxy;
|
||||
import com.opensymphony.xwork2.ActionProxyFactory;
|
||||
import com.opensymphony.xwork2.ObjectFactory;
|
||||
import com.opensymphony.xwork2.config.ConfigurationException;
|
||||
import com.opensymphony.xwork2.config.Configuration;
|
||||
import com.opensymphony.xwork2.util.LocalizedTextUtil;
|
||||
|
||||
/**
|
||||
@@ -169,8 +168,6 @@ public class Jsr168Dispatcher extends GenericPortlet implements StrutsStatics,
|
||||
|
||||
private Dispatcher dispatcherUtils;
|
||||
|
||||
private boolean devMode = false;
|
||||
|
||||
/**
|
||||
* Initialize the portlet with the init parameters from <tt>portlet.xml</tt>
|
||||
*/
|
||||
@@ -212,7 +209,6 @@ public class Jsr168Dispatcher extends GenericPortlet implements StrutsStatics,
|
||||
}
|
||||
|
||||
if ("true".equalsIgnoreCase(Settings.get(StrutsConstants.STRUTS_DEVMODE))) {
|
||||
devMode = true;
|
||||
Settings.set(StrutsConstants.STRUTS_I18N_RELOAD, "true");
|
||||
Settings.set(StrutsConstants.STRUTS_CONFIGURATION_XML_RELOAD, "true");
|
||||
}
|
||||
|
||||
@@ -48,7 +48,6 @@ import org.apache.velocity.context.Context;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* <!-- START SNIPPET: description -->
|
||||
|
||||
@@ -24,7 +24,6 @@ import java.util.Map;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -19,7 +19,6 @@ package org.apache.struts2.util;
|
||||
|
||||
import java.util.Comparator;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
@@ -40,7 +40,6 @@ import org.apache.struts2.views.util.ContextUtil;
|
||||
import com.opensymphony.xwork2.util.FileManager;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.ObjectFactory;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
import freemarker.cache.FileTemplateLoader;
|
||||
import freemarker.cache.MultiTemplateLoader;
|
||||
|
||||
@@ -33,7 +33,6 @@ import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.LocaleProvider;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
import freemarker.template.Configuration;
|
||||
import freemarker.template.ObjectWrapper;
|
||||
|
||||
@@ -23,7 +23,6 @@ import javax.servlet.http.HttpServletResponse;
|
||||
import org.apache.struts2.components.CheckboxList;
|
||||
import org.apache.struts2.components.Component;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,7 +20,6 @@ package org.apache.struts2.views.freemarker.tags;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
|
||||
@@ -25,7 +25,6 @@ import org.apache.struts2.util.FastByteArrayOutputStream;
|
||||
import org.apache.struts2.views.util.ContextUtil;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -37,7 +37,6 @@ import org.apache.struts2.util.AttributeMap;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -31,7 +31,6 @@ import org.apache.struts2.views.jsp.ui.OgnlTool;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
/**
|
||||
* Value Stack's Context related Utilities.
|
||||
|
||||
@@ -93,7 +93,6 @@ import org.apache.velocity.tools.view.servlet.ServletToolboxManager;
|
||||
|
||||
import com.opensymphony.xwork2.ObjectFactory;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -17,19 +17,16 @@
|
||||
*/
|
||||
package org.apache.struts2.views.xslt;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.StringReader;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.parsers.ParserConfigurationException;
|
||||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.struts2.StrutsException;
|
||||
|
||||
import org.w3c.dom.Node;
|
||||
|
||||
import org.xml.sax.InputSource;
|
||||
import org.xml.sax.SAXException;
|
||||
|
||||
import com.opensymphony.xwork2.util.DomHelper;
|
||||
|
||||
|
||||
@@ -33,7 +33,6 @@ import com.opensymphony.xwork2.ActionProxy;
|
||||
import com.opensymphony.xwork2.config.entities.ActionConfig;
|
||||
import com.opensymphony.xwork2.config.entities.ResultConfig;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -37,7 +37,6 @@ import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.config.ConfigurationManager;
|
||||
import com.opensymphony.xwork2.config.entities.PackageConfig;
|
||||
import com.opensymphony.xwork2.mock.MockActionInvocation;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -18,7 +18,6 @@
|
||||
package org.apache.struts2.dispatcher;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Enumeration;
|
||||
import java.util.HashMap;
|
||||
@@ -33,7 +32,6 @@ import junit.framework.TestCase;
|
||||
import com.mockobjects.constraint.Constraint;
|
||||
import com.mockobjects.constraint.IsAnything;
|
||||
import com.mockobjects.constraint.IsEqual;
|
||||
import com.mockobjects.dynamic.ConstraintMatcher;
|
||||
import com.mockobjects.dynamic.Mock;
|
||||
|
||||
|
||||
|
||||
@@ -23,7 +23,6 @@ import org.easymock.EasyMock;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.ActionSupport;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
/**
|
||||
|
||||
@@ -29,7 +29,6 @@ import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.ActionProxy;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@ import org.apache.struts2.StrutsTestCase;
|
||||
import org.apache.struts2.dispatcher.ServletRedirectResult;
|
||||
import org.apache.struts2.views.jsp.StrutsMockHttpServletRequest;
|
||||
|
||||
import com.mockobjects.dynamic.Mock;
|
||||
import com.mockobjects.servlet.MockHttpServletRequest;
|
||||
import com.opensymphony.xwork2.Result;
|
||||
import com.opensymphony.xwork2.config.Configuration;
|
||||
|
||||
@@ -35,7 +35,6 @@ import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionProxy;
|
||||
import com.opensymphony.xwork2.ActionProxyFactory;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -32,7 +32,6 @@ import org.springframework.mock.web.MockHttpServletRequest;
|
||||
import org.springframework.mock.web.MockHttpServletResponse;
|
||||
import org.springframework.mock.web.MockRequestDispatcher;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
@@ -32,7 +32,6 @@ import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.ActionInvocation;
|
||||
import com.opensymphony.xwork2.ActionProxy;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -27,7 +27,6 @@ import org.apache.struts2.components.If;
|
||||
import com.mockobjects.servlet.MockJspWriter;
|
||||
import com.mockobjects.servlet.MockPageContext;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
/**
|
||||
|
||||
@@ -27,7 +27,6 @@ import org.apache.struts2.components.If;
|
||||
import com.mockobjects.servlet.MockJspWriter;
|
||||
import com.mockobjects.servlet.MockPageContext;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -37,7 +37,6 @@ import com.mockobjects.servlet.MockJspWriter;
|
||||
import com.opensymphony.xwork2.Action;
|
||||
import com.opensymphony.xwork2.ActionContext;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ public class MockTag extends BodyTagSupport {
|
||||
}
|
||||
|
||||
public Map getParameters() {
|
||||
return this.params;
|
||||
return MockTag.params;
|
||||
}
|
||||
|
||||
public void setString(String s) {
|
||||
@@ -107,7 +107,7 @@ public class MockTag extends BodyTagSupport {
|
||||
}
|
||||
|
||||
public void addParameter(String key, Object value) {
|
||||
this.params.put(key, value);
|
||||
MockTag.params.put(key, value);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -22,7 +22,6 @@ import junit.framework.TestCase;
|
||||
import org.apache.struts2.StrutsConstants;
|
||||
import org.apache.struts2.config.Settings;
|
||||
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStack;
|
||||
import com.opensymphony.xwork2.util.ValueStackFactory;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user