diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/DispatcherPortlet.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/DispatcherPortlet.java
index 1140845cf27..a5990938150 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/DispatcherPortlet.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/DispatcherPortlet.java
@@ -346,6 +346,7 @@ public class DispatcherPortlet extends FrameworkPortlet {
/**
* This implementation calls {@link #initStrategies}.
*/
+ @Override
public void onRefresh(ApplicationContext context) {
initStrategies(context);
}
@@ -644,6 +645,7 @@ public class DispatcherPortlet extends FrameworkPortlet {
* @param response current portlet Action response
* @throws Exception in case of any kind of processing failure
*/
+ @Override
protected void doActionService(ActionRequest request, ActionResponse response) throws Exception {
if (logger.isDebugEnabled()) {
logger.debug("DispatcherPortlet with name '" + getPortletName() + "' received action request");
@@ -746,6 +748,7 @@ public class DispatcherPortlet extends FrameworkPortlet {
* @param response current portlet render response
* @throws Exception in case of any kind of processing failure
*/
+ @Override
protected void doRenderService(RenderRequest request, RenderResponse response) throws Exception {
if (logger.isDebugEnabled()) {
logger.debug("DispatcherPortlet with name '" + getPortletName() + "' received render request");
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/FrameworkPortlet.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/FrameworkPortlet.java
index 577b3800a1b..170a150ee7c 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/FrameworkPortlet.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/FrameworkPortlet.java
@@ -253,6 +253,7 @@ public abstract class FrameworkPortlet extends GenericPortletBean implements App
* Overridden method of GenericPortletBean, invoked after any bean properties
* have been set. Creates this portlet's ApplicationContext.
*/
+ @Override
protected final void initPortletBean() throws PortletException, BeansException {
getPortletContext().log("Initializing Spring FrameworkPortlet '" + getPortletName() + "'");
if (logger.isInfoEnabled()) {
@@ -435,6 +436,7 @@ public abstract class FrameworkPortlet extends GenericPortletBean implements App
/**
* Overridden for friendlier behavior in unit tests.
*/
+ @Override
protected String getTitle(RenderRequest renderRequest) {
try {
return super.getTitle(renderRequest);
@@ -447,6 +449,7 @@ public abstract class FrameworkPortlet extends GenericPortletBean implements App
/**
* Delegate render requests to processRequest/doRenderService.
*/
+ @Override
protected final void doDispatch(RenderRequest request, RenderResponse response)
throws PortletException, IOException {
@@ -456,6 +459,7 @@ public abstract class FrameworkPortlet extends GenericPortletBean implements App
/**
* Delegate action requests to processRequest/doActionService.
*/
+ @Override
public final void processAction(ActionRequest request, ActionResponse response)
throws PortletException, IOException {
@@ -589,6 +593,7 @@ public abstract class FrameworkPortlet extends GenericPortletBean implements App
* Close the ApplicationContext of this portlet.
* @see org.springframework.context.ConfigurableApplicationContext#close()
*/
+ @Override
public void destroy() {
getPortletContext().log("Destroying Spring FrameworkPortlet '" + getPortletName() + "'");
if (this.portletApplicationContext instanceof ConfigurableApplicationContext) {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/GenericPortletBean.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/GenericPortletBean.java
index c6061072873..e722cb77842 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/GenericPortletBean.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/GenericPortletBean.java
@@ -92,6 +92,7 @@ public abstract class GenericPortletBean extends GenericPortlet {
* @throws PortletException if bean properties are invalid (or required
* properties are missing), or if subclass initialization fails.
*/
+ @Override
public final void init() throws PortletException {
if (logger.isInfoEnabled()) {
logger.info("Initializing portlet '" + getPortletName() + "'");
@@ -135,6 +136,7 @@ public abstract class GenericPortletBean extends GenericPortlet {
* PortletConfig set yet.
* @see #getPortletConfig()
*/
+ @Override
public final String getPortletName() {
return (getPortletConfig() != null ? getPortletConfig().getPortletName() : null);
}
@@ -144,6 +146,7 @@ public abstract class GenericPortletBean extends GenericPortlet {
* PortletConfig set yet.
* @see #getPortletConfig()
*/
+ @Override
public final PortletContext getPortletContext() {
return (getPortletConfig() != null ? getPortletConfig().getPortletContext() : null);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/ModelAndView.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/ModelAndView.java
index c1c08a46eb3..d3a2effdc20 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/ModelAndView.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/ModelAndView.java
@@ -288,6 +288,7 @@ public class ModelAndView {
/**
* Return diagnostic information about this model and view.
*/
+ @Override
public String toString() {
StringBuffer buf = new StringBuffer("ModelAndView: ");
if (isReference()) {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/MissingPortletRequestParameterException.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/MissingPortletRequestParameterException.java
index d2c9cb5862a..05f7e7a5572 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/MissingPortletRequestParameterException.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/MissingPortletRequestParameterException.java
@@ -41,6 +41,7 @@ public class MissingPortletRequestParameterException extends PortletRequestBindi
}
+ @Override
public String getMessage() {
return "Required " + this.parameterType + " parameter '" + parameterName + "' is not present";
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/PortletRequestUtils.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/PortletRequestUtils.java
index 6e13cbded79..d3907daf679 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/PortletRequestUtils.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/bind/PortletRequestUtils.java
@@ -548,10 +548,12 @@ public abstract class PortletRequestUtils {
private static class IntParser extends ParameterParser {
+ @Override
protected String getType() {
return "int";
}
+ @Override
protected Object doParse(String s) throws NumberFormatException {
return Integer.valueOf(s);
}
@@ -573,10 +575,12 @@ public abstract class PortletRequestUtils {
private static class LongParser extends ParameterParser {
+ @Override
protected String getType() {
return "long";
}
+ @Override
protected Object doParse(String parameter) throws NumberFormatException {
return Long.valueOf(parameter);
}
@@ -598,10 +602,12 @@ public abstract class PortletRequestUtils {
private static class FloatParser extends ParameterParser {
+ @Override
protected String getType() {
return "float";
}
+ @Override
protected Object doParse(String parameter) throws NumberFormatException {
return Float.valueOf(parameter);
}
@@ -623,10 +629,12 @@ public abstract class PortletRequestUtils {
private static class DoubleParser extends ParameterParser {
+ @Override
protected String getType() {
return "double";
}
+ @Override
protected Object doParse(String parameter) throws NumberFormatException {
return Double.valueOf(parameter);
}
@@ -648,10 +656,12 @@ public abstract class PortletRequestUtils {
private static class BooleanParser extends ParameterParser {
+ @Override
protected String getType() {
return "boolean";
}
+ @Override
protected Object doParse(String parameter) throws NumberFormatException {
return (parameter.equalsIgnoreCase("true") || parameter.equalsIgnoreCase("on") ||
parameter.equalsIgnoreCase("yes") || parameter.equals("1") ? Boolean.TRUE : Boolean.FALSE);
@@ -674,10 +684,12 @@ public abstract class PortletRequestUtils {
private static class StringParser extends ParameterParser {
+ @Override
protected String getType() {
return "string";
}
+ @Override
protected Object doParse(String parameter) throws NumberFormatException {
return parameter;
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/AbstractRefreshablePortletApplicationContext.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/AbstractRefreshablePortletApplicationContext.java
index 06b509dd375..56540697a3b 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/AbstractRefreshablePortletApplicationContext.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/AbstractRefreshablePortletApplicationContext.java
@@ -85,6 +85,7 @@ public abstract class AbstractRefreshablePortletApplicationContext extends Abstr
setDisplayName("Root PortletApplicationContext");
}
+ @Override
public void setParent(ApplicationContext parent) {
super.setParent(parent);
if (parent instanceof WebApplicationContext) {
@@ -126,6 +127,7 @@ public abstract class AbstractRefreshablePortletApplicationContext extends Abstr
return this.namespace;
}
+ @Override
public String[] getConfigLocations() {
return super.getConfigLocations();
}
@@ -134,6 +136,7 @@ public abstract class AbstractRefreshablePortletApplicationContext extends Abstr
/**
* Register request/session scopes, a {@link PortletContextAwareProcessor}, etc.
*/
+ @Override
protected void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) {
beanFactory.addBeanPostProcessor(new ServletContextAwareProcessor(this.servletContext));
beanFactory.addBeanPostProcessor(new PortletContextAwareProcessor(this.portletContext, this.portletConfig));
@@ -151,6 +154,7 @@ public abstract class AbstractRefreshablePortletApplicationContext extends Abstr
* This implementation supports file paths beneath the root of the PortletContext.
* @see PortletContextResource
*/
+ @Override
protected Resource getResourceByPath(String path) {
return new PortletContextResource(this.portletContext, path);
}
@@ -159,6 +163,7 @@ public abstract class AbstractRefreshablePortletApplicationContext extends Abstr
* This implementation supports pattern matching in unexpanded WARs too.
* @see PortletContextResourcePatternResolver
*/
+ @Override
protected ResourcePatternResolver getResourcePatternResolver() {
return new PortletContextResourcePatternResolver(this);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletApplicationObjectSupport.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletApplicationObjectSupport.java
index 58305c74b3e..574b4d80d7c 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletApplicationObjectSupport.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletApplicationObjectSupport.java
@@ -49,6 +49,7 @@ public abstract class PortletApplicationObjectSupport extends ApplicationObjectS
* @see #getPortletContext()
* @see #getTempDir()
*/
+ @Override
protected boolean isContextRequired() {
return true;
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResource.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResource.java
index 7fc7dcb0c21..ef6dde6d373 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResource.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResource.java
@@ -96,6 +96,7 @@ public class PortletContextResource extends AbstractResource implements ContextR
* This implementation checks PortletContext.getResource.
* @see javax.portlet.PortletContext#getResource(String)
*/
+ @Override
public boolean exists() {
try {
URL url = this.portletContext.getResource(this.path);
@@ -124,6 +125,7 @@ public class PortletContextResource extends AbstractResource implements ContextR
* but throws a FileNotFoundException if no resource found.
* @see javax.portlet.PortletContext#getResource(String)
*/
+ @Override
public URL getURL() throws IOException {
URL url = this.portletContext.getResource(this.path);
if (url == null) {
@@ -138,16 +140,19 @@ public class PortletContextResource extends AbstractResource implements ContextR
* but throws a FileNotFoundException if not found or not resolvable.
* @see javax.portlet.PortletContext#getRealPath(String)
*/
+ @Override
public File getFile() throws IOException {
String realPath = PortletUtils.getRealPath(this.portletContext, this.path);
return new File(realPath);
}
+ @Override
public Resource createRelative(String relativePath) {
String pathToUse = StringUtils.applyRelativePath(this.path, relativePath);
return new PortletContextResource(this.portletContext, pathToUse);
}
+ @Override
public String getFilename() {
return StringUtils.getFilename(this.path);
}
@@ -161,6 +166,7 @@ public class PortletContextResource extends AbstractResource implements ContextR
}
+ @Override
public boolean equals(Object obj) {
if (obj == this) {
return true;
@@ -172,6 +178,7 @@ public class PortletContextResource extends AbstractResource implements ContextR
return false;
}
+ @Override
public int hashCode() {
return this.path.hashCode();
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourceLoader.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourceLoader.java
index d4a7c50b13b..b72541e9e68 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourceLoader.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourceLoader.java
@@ -53,6 +53,7 @@ public class PortletContextResourceLoader extends DefaultResourceLoader {
* This implementation supports file paths beneath the root of the web application.
* @see PortletContextResource
*/
+ @Override
protected Resource getResourceByPath(String path) {
return new PortletContextResource(this.portletContext, path);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourcePatternResolver.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourcePatternResolver.java
index 5f86aa767ee..463161a467b 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourcePatternResolver.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletContextResourcePatternResolver.java
@@ -72,6 +72,7 @@ public class PortletContextResourcePatternResolver extends PathMatchingResourceP
* @see org.springframework.web.portlet.context.PortletContextResource
* @see javax.portlet.PortletContext#getResourcePaths
*/
+ @Override
protected Set doFindPathMatchingFileResources(Resource rootDirResource, String subPattern) throws IOException {
if (rootDirResource instanceof PortletContextResource) {
PortletContextResource pcResource = (PortletContextResource) rootDirResource;
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestAttributes.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestAttributes.java
index 68f3d70c8e5..d67a78ed7d7 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestAttributes.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestAttributes.java
@@ -235,6 +235,7 @@ public class PortletRequestAttributes extends AbstractRequestAttributes {
* Update all accessed session attributes through session.setAttribute
* calls, explicitly indicating to the container that they might have been modified.
*/
+ @Override
protected void updateAccessedSessionAttributes() {
this.session = this.request.getPortletSession(false);
synchronized (this.sessionAttributesToUpdate) {
@@ -280,6 +281,7 @@ public class PortletRequestAttributes extends AbstractRequestAttributes {
}
+ @Override
public String toString() {
return this.request.toString();
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestHandledEvent.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestHandledEvent.java
index 6e3c595f414..4b052eee786 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestHandledEvent.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletRequestHandledEvent.java
@@ -106,6 +106,7 @@ public class PortletRequestHandledEvent extends RequestHandledEvent {
}
+ @Override
public String getShortDescription() {
StringBuffer sb = new StringBuffer();
sb.append("portlet=[").append(this.portletName).append("]; ");
@@ -113,6 +114,7 @@ public class PortletRequestHandledEvent extends RequestHandledEvent {
return sb.toString();
}
+ @Override
public String getDescription() {
StringBuffer sb = new StringBuffer();
sb.append("portlet=[").append(this.portletName).append("]; ");
@@ -122,6 +124,7 @@ public class PortletRequestHandledEvent extends RequestHandledEvent {
return sb.toString();
}
+ @Override
public String toString() {
return "PortletRequestHandledEvent: " + getDescription();
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletWebRequest.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletWebRequest.java
index 78f43086d2b..0c6b454489f 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletWebRequest.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/PortletWebRequest.java
@@ -136,6 +136,7 @@ public class PortletWebRequest extends PortletRequestAttributes implements Nativ
return buffer.toString();
}
+ @Override
public String toString() {
return "PortletWebRequest: " + getDescription(true);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/StaticPortletApplicationContext.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/StaticPortletApplicationContext.java
index ac341f4ad23..9e2b9209585 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/StaticPortletApplicationContext.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/StaticPortletApplicationContext.java
@@ -63,6 +63,7 @@ public class StaticPortletApplicationContext extends StaticApplicationContext
}
+ @Override
public void setParent(ApplicationContext parent) {
super.setParent(parent);
if (parent instanceof WebApplicationContext) {
@@ -132,6 +133,7 @@ public class StaticPortletApplicationContext extends StaticApplicationContext
/**
* Register request/session scopes, a {@link PortletContextAwareProcessor}, etc.
*/
+ @Override
protected void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) {
beanFactory.addBeanPostProcessor(new ServletContextAwareProcessor(this.servletContext));
beanFactory.addBeanPostProcessor(new PortletContextAwareProcessor(this.portletContext, this.portletConfig));
@@ -148,6 +150,7 @@ public class StaticPortletApplicationContext extends StaticApplicationContext
* This implementation supports file paths beneath the root of the PortletContext.
* @see PortletContextResource
*/
+ @Override
protected Resource getResourceByPath(String path) {
return new PortletContextResource(this.portletContext, path);
}
@@ -156,6 +159,7 @@ public class StaticPortletApplicationContext extends StaticApplicationContext
* This implementation supports pattern matching in unexpanded WARs too.
* @see PortletContextResourcePatternResolver
*/
+ @Override
protected ResourcePatternResolver getResourcePatternResolver() {
return new PortletContextResourcePatternResolver(this);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/XmlPortletApplicationContext.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/XmlPortletApplicationContext.java
index c97e50e1b15..6ddb030edb6 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/XmlPortletApplicationContext.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/context/XmlPortletApplicationContext.java
@@ -76,6 +76,7 @@ public class XmlPortletApplicationContext extends AbstractRefreshablePortletAppl
* @see #initBeanDefinitionReader
* @see #loadBeanDefinitions
*/
+ @Override
protected void loadBeanDefinitions(DefaultListableBeanFactory beanFactory) throws IOException {
// Create a new XmlBeanDefinitionReader for the given BeanFactory.
XmlBeanDefinitionReader beanDefinitionReader = new XmlBeanDefinitionReader(beanFactory);
@@ -130,6 +131,7 @@ public class XmlPortletApplicationContext extends AbstractRefreshablePortletAppl
* and "/WEB-INF/test-portlet.xml" for a context with the namespace "test-portlet"
* (like for a DispatcherPortlet instance with the portlet-name "test").
*/
+ @Override
protected String[] getDefaultConfigLocations() {
if (getNamespace() != null) {
return new String[] {DEFAULT_CONFIG_LOCATION_PREFIX + getNamespace() + DEFAULT_CONFIG_LOCATION_SUFFIX};
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractHandlerMapping.java
index b0e2f3cd613..9a3ef4624ec 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractHandlerMapping.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractHandlerMapping.java
@@ -125,6 +125,7 @@ public abstract class AbstractHandlerMapping extends ApplicationObjectSupport
* @see #extendInterceptors(java.util.List)
* @see #initInterceptors()
*/
+ @Override
protected void initApplicationContext() throws BeansException {
extendInterceptors(this.interceptors);
initInterceptors();
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractMapBasedHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractMapBasedHandlerMapping.java
index cc480be06fd..3a2dd132aa3 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractMapBasedHandlerMapping.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/AbstractMapBasedHandlerMapping.java
@@ -66,6 +66,7 @@ public abstract class AbstractMapBasedHandlerMapping extends AbstractHandlerMapp
* Determines a handler for the computed lookup key for the given request.
* @see #getLookupKey
*/
+ @Override
protected Object getHandlerInternal(PortletRequest request) throws Exception {
Object lookupKey = getLookupKey(request);
Object handler = this.handlerMap.get(lookupKey);
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterHandlerMapping.java
index 72571dc93c6..06894ce87bf 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterHandlerMapping.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterHandlerMapping.java
@@ -88,6 +88,7 @@ public class ParameterHandlerMapping extends AbstractMapBasedHandlerMapping {
* to the superclass's initialization.
* @see #registerHandlers
*/
+ @Override
public void initApplicationContext() throws BeansException {
super.initApplicationContext();
registerHandlers(this.parameterMap);
@@ -98,6 +99,7 @@ public class ParameterHandlerMapping extends AbstractMapBasedHandlerMapping {
* @param parameterMap Map with parameter names as keys and handler beans or bean names as values
* @throws BeansException if the handler couldn't be registered
*/
+ @Override
protected void registerHandlers(Map parameterMap) throws BeansException {
if (CollectionUtils.isEmpty(parameterMap)) {
logger.warn("'parameterMap' is empty on ParameterHandlerMapping");
@@ -112,6 +114,7 @@ public class ParameterHandlerMapping extends AbstractMapBasedHandlerMapping {
* Uses the value of the specified parameter as lookup key.
* @see #setParameterName
*/
+ @Override
protected Object getLookupKey(PortletRequest request) throws Exception {
return request.getParameter(this.parameterName);
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterMappingInterceptor.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterMappingInterceptor.java
index 153be429106..cd5f1570115 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterMappingInterceptor.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/ParameterMappingInterceptor.java
@@ -65,6 +65,7 @@ public class ParameterMappingInterceptor extends HandlerInterceptorAdapter {
* If request is an {@link javax.portlet.ActionRequest ActionRequest},
* get handler mapping parameter and add it to the ActionResponse.
*/
+ @Override
public boolean preHandleAction(ActionRequest request, ActionResponse response, Object handler) {
String mappingParameter = request.getParameter(this.parameterName);
if (mappingParameter != null) {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeHandlerMapping.java
index 2992517d88c..19a294d072f 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeHandlerMapping.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeHandlerMapping.java
@@ -76,6 +76,7 @@ public class PortletModeHandlerMapping extends AbstractMapBasedHandlerMapping {
* to the superclass's initialization.
* @see #registerHandlers
*/
+ @Override
public void initApplicationContext() throws BeansException {
super.initApplicationContext();
registerHandlers(this.portletModeMap);
@@ -86,6 +87,7 @@ public class PortletModeHandlerMapping extends AbstractMapBasedHandlerMapping {
* @param portletModeMap Map with mode names as keys and handler beans or bean names as values
* @throws BeansException if the handler couldn't be registered
*/
+ @Override
protected void registerHandlers(Map portletModeMap) throws BeansException {
if (CollectionUtils.isEmpty(portletModeMap)) {
logger.warn("Neither 'portletModeMap' nor 'mappings' set on PortletModeHandlerMapping");
@@ -105,6 +107,7 @@ public class PortletModeHandlerMapping extends AbstractMapBasedHandlerMapping {
/**
* Uses the current PortletMode as lookup key.
*/
+ @Override
protected Object getLookupKey(PortletRequest request) throws Exception {
return request.getPortletMode();
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeParameterHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeParameterHandlerMapping.java
index e6795245956..af7ed5ec9f2 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeParameterHandlerMapping.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/PortletModeParameterHandlerMapping.java
@@ -137,6 +137,7 @@ public class PortletModeParameterHandlerMapping extends AbstractMapBasedHandlerM
* to the superclass's initialization.
* @see #registerHandlers
*/
+ @Override
public void initApplicationContext() throws BeansException {
super.initApplicationContext();
registerHandlers(this.portletModeParameterMap);
@@ -147,6 +148,7 @@ public class PortletModeParameterHandlerMapping extends AbstractMapBasedHandlerM
* @param portletModeParameterMap Map with mode names as keys and parameter Maps as values
* @throws BeansException if the handler couldn't be registered
*/
+ @Override
protected void registerHandlers(Map portletModeParameterMap) throws BeansException {
if (CollectionUtils.isEmpty(portletModeParameterMap)) {
logger.warn("'portletModeParameterMap' not set on PortletModeParameterHandlerMapping");
@@ -210,6 +212,7 @@ public class PortletModeParameterHandlerMapping extends AbstractMapBasedHandlerM
* @see javax.portlet.PortletRequest#getPortletMode()
* @see #setParameterName
*/
+ @Override
protected Object getLookupKey(PortletRequest request) throws Exception {
PortletMode mode = request.getPortletMode();
String parameter = request.getParameter(this.parameterName);
@@ -231,6 +234,7 @@ public class PortletModeParameterHandlerMapping extends AbstractMapBasedHandlerM
this.parameter = parameter;
}
+ @Override
public boolean equals(Object other) {
if (this == other) {
return true;
@@ -243,10 +247,12 @@ public class PortletModeParameterHandlerMapping extends AbstractMapBasedHandlerM
ObjectUtils.nullSafeEquals(this.parameter, otherKey.parameter));
}
+ @Override
public int hashCode() {
return (this.mode.hashCode() * 29 + ObjectUtils.nullSafeHashCode(this.parameter));
}
+ @Override
public String toString() {
return "Portlet mode '" + this.mode + "', parameter '" + this.parameter + "'";
}
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/UserRoleAuthorizationInterceptor.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/UserRoleAuthorizationInterceptor.java
index dc876fc1edb..14c9f7a63f6 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/UserRoleAuthorizationInterceptor.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/handler/UserRoleAuthorizationInterceptor.java
@@ -46,6 +46,7 @@ public class UserRoleAuthorizationInterceptor extends HandlerInterceptorAdapter
}
+ @Override
public final boolean preHandle(PortletRequest request, PortletResponse response, Object handler)
throws PortletException, IOException {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/CommonsPortletMultipartResolver.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/CommonsPortletMultipartResolver.java
index 97faf039ba5..0a665606d99 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/CommonsPortletMultipartResolver.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/CommonsPortletMultipartResolver.java
@@ -106,6 +106,7 @@ public class CommonsPortletMultipartResolver extends CommonsFileUploadSupport
* instance. Can be overridden to use a custom subclass, e.g. for testing purposes.
* @return the new PortletFileUpload instance
*/
+ @Override
protected FileUpload newFileUpload(FileItemFactory fileItemFactory) {
return new PortletFileUpload(fileItemFactory);
}
@@ -133,6 +134,7 @@ public class CommonsPortletMultipartResolver extends CommonsFileUploadSupport
Assert.notNull(request, "Request must not be null");
if (this.resolveLazily) {
return new DefaultMultipartActionRequest(request) {
+ @Override
protected void initializeMultipart() {
MultipartParsingResult parsingResult = parseRequest(request);
setMultipartFiles(parsingResult.getMultipartFiles());
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/DefaultMultipartActionRequest.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/DefaultMultipartActionRequest.java
index a9bc27105b3..155fdf1ee15 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/DefaultMultipartActionRequest.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/multipart/DefaultMultipartActionRequest.java
@@ -79,6 +79,7 @@ public class DefaultMultipartActionRequest extends ActionRequestWrapper implemen
}
+ @Override
public Enumeration getParameterNames() {
Set paramNames = new HashSet();
Enumeration paramEnum = super.getParameterNames();
@@ -89,6 +90,7 @@ public class DefaultMultipartActionRequest extends ActionRequestWrapper implemen
return Collections.enumeration(paramNames);
}
+ @Override
public String getParameter(String name) {
String[] values = (String[]) getMultipartParameters().get(name);
if (values != null) {
@@ -97,6 +99,7 @@ public class DefaultMultipartActionRequest extends ActionRequestWrapper implemen
return super.getParameter(name);
}
+ @Override
public String[] getParameterValues(String name) {
String[] values = (String[]) getMultipartParameters().get(name);
if (values != null) {
@@ -105,6 +108,7 @@ public class DefaultMultipartActionRequest extends ActionRequestWrapper implemen
return super.getParameterValues(name);
}
+ @Override
public Map getParameterMap() {
Map paramMap = new HashMap();
paramMap.putAll(super.getParameterMap());
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractCommandController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractCommandController.java
index d48cde1c99c..f354e1dc1ec 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractCommandController.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractCommandController.java
@@ -86,6 +86,7 @@ public abstract class AbstractCommandController extends BaseCommandController {
}
+ @Override
protected final void handleActionRequestInternal(ActionRequest request, ActionResponse response)
throws Exception {
@@ -104,6 +105,7 @@ public abstract class AbstractCommandController extends BaseCommandController {
setCommandInSession(response);
}
+ @Override
protected final ModelAndView handleRenderRequestInternal(
RenderRequest request, RenderResponse response) throws Exception {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractFormController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractFormController.java
index a1ec01b9f23..cb5b7110a1c 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractFormController.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractFormController.java
@@ -371,6 +371,7 @@ public abstract class AbstractFormController extends BaseCommandController {
* @see #processFormSubmission
* @see #handleRenderRequestInternal
*/
+ @Override
protected void handleActionRequestInternal(ActionRequest request, ActionResponse response)
throws Exception {
@@ -420,6 +421,7 @@ public abstract class AbstractFormController extends BaseCommandController {
* @see #processFormSubmission
* @see #handleActionRequestInternal
*/
+ @Override
protected ModelAndView handleRenderRequestInternal(RenderRequest request, RenderResponse response)
throws Exception {
@@ -680,6 +682,7 @@ public abstract class AbstractFormController extends BaseCommandController {
* @return object form to bind onto
* @see #formBackingObject
*/
+ @Override
protected final Object getCommand(PortletRequest request) throws Exception {
// If not in session-form mode, create a new form-backing object.
if (!isSessionForm()) {
diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractWizardFormController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractWizardFormController.java
index 632985e0fea..3ff16a1bede 100644
--- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractWizardFormController.java
+++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/AbstractWizardFormController.java
@@ -230,6 +230,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
/**
* Calls page-specific onBindAndValidate method.
*/
+ @Override
protected final void onBindAndValidate(PortletRequest request, Object command, BindException errors)
throws Exception {
@@ -261,6 +262,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
* @see #isFinishRequest(PortletRequest)
* @see #isCancelRequest(PortletRequest)
*/
+ @Override
protected boolean isFormSubmission(PortletRequest request) {
return super.isFormSubmission(request) || isFinishRequest(request) || isCancelRequest(request);
}
@@ -268,6 +270,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
/**
* Calls page-specific referenceData method.
*/
+ @Override
protected final Map referenceData(PortletRequest request, Object command, Errors errors)
throws Exception {
@@ -315,6 +318,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
*
This can be overridden in subclasses, e.g. to prepare wizard-specific * error views in case of an Exception. */ + @Override protected ModelAndView showForm( RenderRequest request, RenderResponse response, BindException errors) throws Exception { @@ -557,6 +561,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle * @see #setBindOnNewForm * @see #handleInvalidSubmit */ + @Override protected ModelAndView renderInvalidSubmit(RenderRequest request, RenderResponse response) throws Exception { @@ -574,6 +579,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle * @throws Exception in case of errors * @see #renderInvalidSubmit */ + @Override protected void handleInvalidSubmit(ActionRequest request, ActionResponse response) throws Exception { } @@ -581,6 +587,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle * Apply wizard workflow: finish, cancel, page change. * @see #processFormSubmission */ + @Override protected final ModelAndView renderFormSubmission(RenderRequest request, RenderResponse response, Object command, BindException errors) throws Exception { @@ -626,6 +633,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle * Apply wizard workflow: finish, cancel, page change. * @see #renderFormSubmission */ + @Override protected final void processFormSubmission( ActionRequest request, ActionResponse response, Object command, BindException errors) throws Exception { diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/BaseCommandController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/BaseCommandController.java index eaa296d20e2..4780708adaf 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/BaseCommandController.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/BaseCommandController.java @@ -349,6 +349,7 @@ public abstract class BaseCommandController extends AbstractController { } + @Override protected void initApplicationContext() { if (this.validators != null) { for (int i = 0; i < this.validators.length; i++) { diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/ParameterizableViewController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/ParameterizableViewController.java index 7c93b6ec733..5fdfd335968 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/ParameterizableViewController.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/ParameterizableViewController.java @@ -81,6 +81,7 @@ public class ParameterizableViewController extends AbstractController { return this.viewName; } + @Override protected void initApplicationContext() { if (this.viewName == null) { throw new IllegalArgumentException("Property 'viewName' is required"); @@ -91,6 +92,7 @@ public class ParameterizableViewController extends AbstractController { /** * Return a ModelAndView object with the specified view name. */ + @Override protected ModelAndView handleRenderRequestInternal(RenderRequest request, RenderResponse response) throws Exception { diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/PortletWrappingController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/PortletWrappingController.java index 470bdfb8339..57abfc20cda 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/PortletWrappingController.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/PortletWrappingController.java @@ -98,6 +98,7 @@ public class PortletWrappingController extends AbstractController this.useSharedPortletConfig = useSharedPortletConfig; } + @Override public void setPortletContext(PortletContext portletContext) { this.portletContext = portletContext; } @@ -156,12 +157,14 @@ public class PortletWrappingController extends AbstractController } + @Override protected void handleActionRequestInternal( ActionRequest request, ActionResponse response) throws Exception { this.portletInstance.processAction(request, response); } + @Override protected ModelAndView handleRenderRequestInternal( RenderRequest request, RenderResponse response) throws Exception { diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/SimpleFormController.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/SimpleFormController.java index d290253b73a..b3d3fc95621 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/SimpleFormController.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/SimpleFormController.java @@ -200,6 +200,7 @@ public class SimpleFormController extends AbstractFormController { * @see #setFormView * @see #showForm(RenderRequest, RenderResponse, BindException, Map) */ + @Override protected ModelAndView showForm(RenderRequest request, RenderResponse response, BindException errors) throws Exception { @@ -238,6 +239,7 @@ public class SimpleFormController extends AbstractFormController { * @throws Exception in case of invalid state or arguments * @see ModelAndView */ + @Override protected Map referenceData(PortletRequest request, Object command, Errors errors) throws Exception { return referenceData(request); } @@ -271,6 +273,7 @@ public class SimpleFormController extends AbstractFormController { * @see #onSubmitRender(Object) * @see #processFormSubmission(ActionRequest, ActionResponse, Object, BindException) */ + @Override protected ModelAndView renderFormSubmission(RenderRequest request, RenderResponse response, Object command, BindException errors) throws Exception { @@ -296,6 +299,7 @@ public class SimpleFormController extends AbstractFormController { * @see #doSubmitAction(Object) * @see #renderFormSubmission(RenderRequest, RenderResponse, Object, BindException) */ + @Override protected void processFormSubmission( ActionRequest request, ActionResponse response, Object command, BindException errors) throws Exception { @@ -329,6 +333,7 @@ public class SimpleFormController extends AbstractFormController { * and should not get validated but just show the new form. * @see #isFormChangeRequest */ + @Override protected boolean suppressValidation(PortletRequest request) { return isFormChangeRequest(request); } diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/AnnotationMethodHandlerAdapter.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/AnnotationMethodHandlerAdapter.java index 545df19d3f8..c8e20c22f52 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/AnnotationMethodHandlerAdapter.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/AnnotationMethodHandlerAdapter.java @@ -592,12 +592,14 @@ public class AnnotationMethodHandlerAdapter extends PortletContentGenerator impl private boolean render = false; + @Override public boolean equals(Object obj) { RequestMappingInfo other = (RequestMappingInfo) obj; return (this.action == other.action && this.render == other.render && Arrays.equals(this.modes, other.modes) && Arrays.equals(this.params, other.params)); } + @Override public int hashCode() { return (Arrays.hashCode(this.modes) * 29 + Arrays.hashCode(this.params)); } diff --git a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/DefaultAnnotationHandlerMapping.java b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/DefaultAnnotationHandlerMapping.java index 4c3db085504..067b908e7ca 100644 --- a/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/DefaultAnnotationHandlerMapping.java +++ b/org.springframework.web.portlet/src/main/java/org/springframework/web/portlet/mvc/annotation/DefaultAnnotationHandlerMapping.java @@ -84,6 +84,7 @@ public class DefaultAnnotationHandlerMapping extends AbstractMapBasedHandlerMapp * to the superclass's initialization. * @see #detectHandlers */ + @Override public void initApplicationContext() throws BeansException { super.initApplicationContext(); detectHandlers(); @@ -165,6 +166,7 @@ public class DefaultAnnotationHandlerMapping extends AbstractMapBasedHandlerMapp /** * Uses the current PortletMode as lookup key. */ + @Override protected Object getLookupKey(PortletRequest request) throws Exception { return request.getPortletMode(); } @@ -194,6 +196,7 @@ public class DefaultAnnotationHandlerMapping extends AbstractMapBasedHandlerMapp } } + @Override public String toString() { return StringUtils.arrayToCommaDelimitedString(this.params); }