Consistent formatting of license headers, package javadocs, and import declarations

This commit is contained in:
Juergen Hoeller
2014-10-21 00:30:42 +02:00
parent b6fdcffc94
commit 8325b10080
2059 changed files with 3944 additions and 5473 deletions

View File

@@ -29,14 +29,14 @@ import org.apache.http.nio.client.HttpAsyncClient;
import org.apache.http.nio.entity.NByteArrayEntity;
import org.apache.http.protocol.HttpContext;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
import org.springframework.util.concurrent.FailureCallback;
import org.springframework.util.concurrent.FutureAdapter;
import org.springframework.util.concurrent.ListenableFuture;
import org.springframework.util.concurrent.ListenableFutureCallback;
import org.springframework.util.concurrent.ListenableFutureCallbackRegistry;
import org.springframework.util.concurrent.SuccessCallback;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
/**

View File

@@ -22,6 +22,7 @@ import java.io.InputStream;
import org.apache.http.Header;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.springframework.http.HttpHeaders;
/**

View File

@@ -1,10 +1,6 @@
/**
*
* Contains an abstraction over client-side HTTP. This package
* contains the {@code ClientHttpRequest} and
* {@code ClientHttpResponse}, as well as a basic implementation of these
* interfaces.
*
* contains the {@code ClientHttpRequest} and {@code ClientHttpResponse},
* as well as a basic implementation of these interfaces.
*/
package org.springframework.http.client;

View File

@@ -21,6 +21,7 @@ import java.net.URI;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.http.HttpMethod;
import org.springframework.http.client.AsyncClientHttpRequest;
import org.springframework.http.client.AsyncClientHttpRequestFactory;

View File

@@ -22,11 +22,11 @@ import java.net.URI;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.util.Assert;
import org.springframework.http.HttpMethod;
import org.springframework.http.client.ClientHttpRequest;
import org.springframework.http.client.ClientHttpRequestFactory;
import org.springframework.http.client.SimpleClientHttpRequestFactory;
import org.springframework.util.Assert;
/**
* Base class for {@link org.springframework.web.client.RestTemplate}

View File

@@ -1,9 +1,5 @@
/**
*
* This package provides generic HTTP support classes,
* to be used by higher-level classes like RestTemplate.
*
*/
package org.springframework.http.client.support;

View File

@@ -1,8 +1,5 @@
/**
*
* Provides HttpMessageConverter implementations for handling Atom and RSS feeds.
* Based on the <a href="https://github.com/rometools/rome">ROME tools</a> project.
*
*/
package org.springframework.http.converter.feed;

View File

@@ -5,7 +5,7 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,

View File

@@ -1,23 +1,4 @@
/*
* Copyright 2002-2010 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
*
* Provides an HttpMessageConverter implementations for handling JSON.
*
*/
package org.springframework.http.converter.json;

View File

@@ -1,24 +1,4 @@
/*
* Copyright 2002-2010 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
*
* Provides an HttpMessageConverter abstraction to convert between Java objects and HTTP input/output messages.
*
*/
package org.springframework.http.converter;

View File

@@ -17,7 +17,6 @@
package org.springframework.http.converter.xml;
import java.io.IOException;
import javax.xml.transform.Result;
import javax.xml.transform.Source;

View File

@@ -1,24 +1,4 @@
/*
* Copyright 2002-2010 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
*
* Provides an HttpMessageConverter implementations for handling XML.
*
*/
package org.springframework.http.converter.xml;

View File

@@ -1,8 +1,5 @@
/**
*
* Contains a basic abstraction over client/server-side HTTP. This package contains
* the {@code HttpInputMessage} and {@code HttpOutputMessage} interfaces.
*
*/
package org.springframework.http;

View File

@@ -18,7 +18,6 @@ package org.springframework.http.server;
import java.io.IOException;
import java.util.concurrent.atomic.AtomicBoolean;
import javax.servlet.AsyncContext;
import javax.servlet.AsyncEvent;
import javax.servlet.AsyncListener;

View File

@@ -1,10 +1,6 @@
/**
*
* Contains an abstraction over server-side HTTP. This package
* contains the {@code ServerHttpRequest} and
* {@code ServerHttpResponse}, as well as a Servlet-based implementation of these
* interfaces.
*
* contains the {@code ServerHttpRequest} and {@code ServerHttpResponse},
* as well as a Servlet-based implementation of these interfaces.
*/
package org.springframework.http.server;

View File

@@ -17,7 +17,6 @@
package org.springframework.remoting.caucho;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

View File

@@ -33,8 +33,8 @@ import com.caucho.hessian.io.HessianOutput;
import com.caucho.hessian.io.HessianRemoteResolver;
import com.caucho.hessian.io.SerializerFactory;
import com.caucho.hessian.server.HessianSkeleton;
import org.apache.commons.logging.Log;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.remoting.support.RemoteExporter;
import org.springframework.util.Assert;

View File

@@ -1,18 +1,10 @@
/**
*
* This package provides remoting classes for Caucho's Hessian and Burlap
* protocols: a proxy factory for accessing Hessian/Burlap services,
* and an exporter for making beans available to Hessian/Burlap clients.
* This package provides remoting classes for Caucho's Hessian protocol:
* a proxy factory for accessing Hessian services, and an exporter for
* making beans available to Hessian clients.
*
* <p>Hessian is a slim, binary RPC protocol over HTTP.
* For information on Hessian, see the
* <a href="http://www.caucho.com/hessian">Hessian website</a>
*
* <p>Burlap is a slim, XML-based RPC protocol over HTTP.
* For information on Burlap, see the
* <a href="http://www.caucho.com/burlap">Burlap website</a>
*
*/
package org.springframework.remoting.caucho;

View File

@@ -29,6 +29,7 @@ import org.apache.http.StatusLine;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.ByteArrayEntity;
import org.springframework.context.i18n.LocaleContext;
import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.remoting.support.RemoteInvocationResult;

View File

@@ -1,6 +1,4 @@
/**
*
* Remoting classes for transparent Java-to-Java remoting via HTTP invokers.
* Uses Java serialization just like RMI, but provides the same ease of setup
* as Caucho's HTTP-based Hessian and Burlap protocols.
@@ -9,7 +7,5 @@
* It is more powerful and more extensible than Hessian and Burlap, at the
* expense of being tied to Java. Neverthelesss, it is as easy to set up as
* Hessian and Burlap, which is its main advantage compared to RMI.
*
*/
package org.springframework.remoting.httpinvoker;

View File

@@ -1,10 +1,6 @@
/**
*
* Remoting classes for Web Services via JAX-WS (the successor of JAX-RPC),
* as included in Java 6 and Java EE 5. This package provides proxy
* factories for accessing JAX-WS services and ports.
*
*/
package org.springframework.remoting.jaxws;

View File

@@ -17,7 +17,6 @@
package org.springframework.web;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

View File

@@ -21,6 +21,7 @@ import java.util.List;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.http.MediaType;
import org.springframework.web.context.request.NativeWebRequest;

View File

@@ -20,6 +20,7 @@ import java.util.Map;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.http.MediaType;
import org.springframework.util.Assert;
import org.springframework.web.HttpMediaTypeNotAcceptableException;

View File

@@ -20,13 +20,13 @@ import java.io.IOException;
import java.io.InputStream;
import java.util.Locale;
import java.util.Map;
import javax.activation.FileTypeMap;
import javax.activation.MimetypesFileTypeMap;
import javax.servlet.http.HttpServletRequest;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.http.MediaType;

View File

@@ -16,7 +16,6 @@
package org.springframework.web.accept;
import java.util.Map;
import javax.servlet.ServletContext;
import org.springframework.http.MediaType;

View File

@@ -1,4 +1,3 @@
/**
* This package contains classes used to determine the requested the media types in a request.
*
@@ -14,4 +13,3 @@
* ore more of the above strategies in a specific order.
*/
package org.springframework.web.accept;

View File

@@ -1,9 +1,5 @@
/**
*
* Annotations for binding requests to controllers and handler methods
* as well as for binding request parameters to method arguments.
*
*/
package org.springframework.web.bind.annotation;

View File

@@ -34,6 +34,7 @@ import java.util.Set;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.core.BridgeMethodResolver;

View File

@@ -1,8 +1,4 @@
/**
*
* Support classes for web annotation processing.
*
*/
package org.springframework.web.bind.annotation.support;

View File

@@ -1,8 +1,4 @@
/**
*
* Provides web-specific data binding functionality.
*
*/
package org.springframework.web.bind;

View File

@@ -1,8 +1,4 @@
/**
*
* Support classes for web data binding.
*
*/
package org.springframework.web.bind.support;

View File

@@ -1,9 +1,5 @@
/**
*
* Core package of the client-side web support.
* Provides a RestTemplate class and various callback interfaces.
*
*/
package org.springframework.web.client;

View File

@@ -1,8 +1,5 @@
/**
*
* Classes supporting the {@code org.springframework.web.client} package.
* Contains a base class for RestTemplate usage.
*
*/
package org.springframework.web.client.support;

View File

@@ -1,9 +1,5 @@
/**
*
* Contains a variant of the application context interface for web applications,
* and the ContextLoaderListener that bootstraps a root web application context.
*
*/
package org.springframework.web.context;

View File

@@ -18,6 +18,7 @@ package org.springframework.web.context.request;
import org.apache.log4j.Logger;
import org.apache.log4j.NDC;
import org.springframework.ui.ModelMap;
/**

View File

@@ -20,6 +20,7 @@ import java.util.concurrent.Callable;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.web.context.request.NativeWebRequest;
/**

View File

@@ -20,6 +20,7 @@ import java.util.concurrent.Callable;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.util.Assert;
import org.springframework.web.context.request.NativeWebRequest;

View File

@@ -19,6 +19,7 @@ import java.util.List;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.web.context.request.NativeWebRequest;
/**

View File

@@ -20,7 +20,6 @@ import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.atomic.AtomicBoolean;
import javax.servlet.AsyncContext;
import javax.servlet.AsyncEvent;
import javax.servlet.AsyncListener;

View File

@@ -16,7 +16,6 @@
package org.springframework.web.context.request.async;
import java.util.concurrent.Callable;
import javax.servlet.http.HttpServletResponse;
import org.springframework.http.HttpStatus;

View File

@@ -16,7 +16,6 @@
package org.springframework.web.context.request.async;
import java.lang.reflect.Constructor;
import javax.servlet.ServletRequest;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

View File

@@ -1,10 +1,4 @@
/**
*
* Support for asynchronous request processing.
*
* @since 3.2
*
*/
package org.springframework.web.context.request.async;

View File

@@ -1,9 +1,5 @@
/**
*
* Support for generic request context holding, in particular for
* scoping of application objects per HTTP request or HTTP session.
*
*/
package org.springframework.web.context.request;

View File

@@ -18,7 +18,6 @@ package org.springframework.web.context.support;
import java.util.HashSet;
import java.util.Set;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletRequestWrapper;

View File

@@ -17,7 +17,6 @@
package org.springframework.web.context.support;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;

View File

@@ -17,7 +17,6 @@
package org.springframework.web.context.support;
import java.util.Properties;
import javax.servlet.ServletContext;
import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer;

View File

@@ -1,8 +1,5 @@
/**
*
* Classes supporting the {@code org.springframework.web.context} package,
* such as WebApplicationContext implementations and various utility classes.
*
*/
package org.springframework.web.context.support;

View File

@@ -19,7 +19,6 @@ package org.springframework.web.filter;
import java.util.Enumeration;
import java.util.HashSet;
import java.util.Set;
import javax.servlet.Filter;
import javax.servlet.FilterConfig;
import javax.servlet.ServletContext;
@@ -27,6 +26,7 @@ import javax.servlet.ServletException;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.BeanWrapper;
import org.springframework.beans.BeansException;
import org.springframework.beans.MutablePropertyValues;
@@ -44,8 +44,8 @@ import org.springframework.core.io.ResourceLoader;
import org.springframework.util.Assert;
import org.springframework.util.StringUtils;
import org.springframework.web.context.ServletContextAware;
import org.springframework.web.context.support.StandardServletEnvironment;
import org.springframework.web.context.support.ServletContextResourceLoader;
import org.springframework.web.context.support.StandardServletEnvironment;
import org.springframework.web.util.NestedServletException;
/**

View File

@@ -28,7 +28,6 @@ import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import javax.servlet.FilterChain;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;

View File

@@ -1,8 +1,4 @@
/**
*
* Provides generic filter base classes allowing for bean-style configuration.
*
*/
package org.springframework.web.filter;

View File

@@ -1,9 +1,5 @@
/**
*
* ELResolvers for integrating a JSF web tier with a Spring middle tier
* ELResolvers for integrating a JSF web layer with a Spring service layer
* which is hosted in a Spring root WebApplicationContext.
*
*/
package org.springframework.web.jsf.el;

View File

@@ -1,12 +1,8 @@
/**
*
* Support classes for integrating a JSF web tier with a Spring middle tier
* Support classes for integrating a JSF web layer with a Spring service layer
* which is hosted in a Spring root WebApplicationContext.
*
* <p>Supports easy access to beans in the Spring root WebApplicationContext
* from JSF EL expressions, for example in property values of JSF-managed beans.
*
*/
package org.springframework.web.jsf;

View File

@@ -24,7 +24,6 @@ import org.springframework.beans.factory.config.BeanExpressionContext;
import org.springframework.beans.factory.config.BeanExpressionResolver;
import org.springframework.beans.factory.config.ConfigurableBeanFactory;
import org.springframework.core.MethodParameter;
import org.springframework.util.Assert;
import org.springframework.web.bind.WebDataBinder;
import org.springframework.web.bind.annotation.ValueConstants;
import org.springframework.web.bind.support.WebDataBinderFactory;

View File

@@ -26,6 +26,7 @@ import java.util.Set;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.BeanUtils;
import org.springframework.core.Conventions;
import org.springframework.core.GenericTypeResolver;

View File

@@ -1,8 +1,4 @@
/**
*
* Support classes for annotation-based handler method processing.
*
*/
package org.springframework.web.method.annotation;

View File

@@ -1,8 +1,5 @@
/**
*
* Common infrastructure for handler method processing, as used by
* Spring MVC's {@code org.springframework.web.servlet.mvc.method} package.
*
*/
package org.springframework.web.method;

View File

@@ -5,7 +5,7 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,

View File

@@ -1,8 +1,4 @@
/**
*
* Generic support classes for handler method processing.
*
*/
package org.springframework.web.method.support;

View File

@@ -21,6 +21,7 @@ import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
import org.apache.commons.fileupload.FileItem;
import org.apache.commons.fileupload.FileUploadException;
import org.apache.commons.fileupload.disk.DiskFileItem;

View File

@@ -1,9 +1,5 @@
/**
*
* MultipartResolver implementation for
* <a href="http://jakarta.apache.org/commons/fileupload">Jakarta Commons FileUpload</a>.
*
*/
package org.springframework.web.multipart.commons;

View File

@@ -1,11 +1,7 @@
/**
*
* Multipart resolution framework for handling file uploads.
* Provides a MultipartResolver strategy interface,
* and a generic extension of the HttpServletRequest interface
* for accessing multipart files in web application code.
*
*/
package org.springframework.web.multipart;

View File

@@ -19,7 +19,6 @@ package org.springframework.web.multipart.support;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import javax.servlet.http.HttpServletRequest;
import org.springframework.http.HttpHeaders;

View File

@@ -1,10 +1,6 @@
/**
*
* Support classes for the multipart resolution framework.
* Contains property editors for multipart files, and a
* servlet filter for multipart handling without Spring's web MVC.
*
* Contains property editors for multipart files, and a Servlet filter
* for multipart handling without Spring's Web MVC.
*/
package org.springframework.web.multipart.support;

View File

@@ -1,9 +1,5 @@
/**
*
* Common, generic interfaces that define minimal boundary points
* between Spring's web infrastructure and other framework modules.
*
*/
package org.springframework.web;

View File

@@ -17,7 +17,6 @@
package org.springframework.web.util;
import java.io.Serializable;
import javax.servlet.http.HttpSessionEvent;
import javax.servlet.http.HttpSessionListener;

View File

@@ -17,7 +17,6 @@
package org.springframework.web.util;
import java.beans.Introspector;
import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;

View File

@@ -1,9 +1,5 @@
/**
*
* Miscellaneous web utility classes, such as HTML escaping,
* log4j initialization, and cookie handling.
*
* Log4j initialization, and cookie handling.
*/
package org.springframework.web.util;

View File

@@ -16,12 +16,13 @@
package org.springframework.http;
import static org.junit.Assert.*;
import org.junit.Test;
import org.springframework.util.LinkedMultiValueMap;
import org.springframework.util.MultiValueMap;
import static org.junit.Assert.*;
/**
* @author Arjen Poutsma
*/

View File

@@ -23,6 +23,7 @@ import java.util.List;
import java.util.Random;
import org.junit.Test;
import org.springframework.core.convert.ConversionService;
import org.springframework.core.convert.support.DefaultConversionService;

View File

@@ -24,6 +24,7 @@ import java.util.Locale;
import org.junit.Before;
import org.junit.Test;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpStatus;
import org.springframework.http.StreamingHttpOutputMessage;

View File

@@ -19,7 +19,6 @@ package org.springframework.http.client;
import java.io.IOException;
import java.io.InputStream;
import java.util.Enumeration;
import javax.servlet.GenericServlet;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
@@ -31,7 +30,6 @@ import javax.servlet.http.HttpServletResponse;
import org.eclipse.jetty.server.Server;
import org.eclipse.jetty.servlet.ServletContextHandler;
import org.eclipse.jetty.servlet.ServletHolder;
import org.junit.AfterClass;
import org.junit.BeforeClass;

View File

@@ -19,6 +19,7 @@ package org.springframework.http.client;
import java.net.ProtocolException;
import org.junit.Test;
import org.springframework.http.HttpMethod;
public class BufferedSimpleHttpRequestFactoryTests extends AbstractHttpRequestFactoryTestCase {

View File

@@ -16,8 +16,6 @@
package org.springframework.http.client;
import static org.junit.Assert.*;
import java.net.URI;
import org.apache.http.client.HttpClient;
@@ -27,8 +25,11 @@ import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.http.params.CoreConnectionPNames;
import org.junit.Test;
import org.springframework.http.HttpMethod;
import static org.junit.Assert.*;
public class HttpComponentsClientHttpRequestFactoryTests extends AbstractHttpRequestFactoryTestCase {
@Override

View File

@@ -28,6 +28,7 @@ import java.util.List;
import org.junit.Before;
import org.junit.Test;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpRequest;

View File

@@ -22,15 +22,15 @@ import java.net.URI;
import java.util.Collections;
import java.util.Random;
import org.junit.Ignore;
import org.junit.Test;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpRequest;
import org.springframework.http.HttpStatus;
import org.junit.Ignore;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.*;
public class StreamingSimpleHttpRequestFactoryTests extends AbstractHttpRequestFactoryTestCase {

View File

@@ -19,10 +19,11 @@ package org.springframework.http.client.support;
import java.net.InetSocketAddress;
import java.net.Proxy;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* @author Arjen Poutsma
*/

View File

@@ -21,7 +21,6 @@ import java.io.ByteArrayInputStream;
import java.io.IOException;
import javax.imageio.ImageIO;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
@@ -32,6 +31,8 @@ import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import org.springframework.util.FileCopyUtils;
import static org.junit.Assert.*;
public class BufferedImageHttpMessageConverterTests {
private BufferedImageHttpMessageConverter converter;

View File

@@ -18,7 +18,6 @@ package org.springframework.http.converter;
import java.io.IOException;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
@@ -26,6 +25,8 @@ import org.springframework.http.MediaType;
import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import static org.junit.Assert.*;
/** @author Arjen Poutsma */
public class ByteArrayHttpMessageConverterTests {

View File

@@ -22,7 +22,6 @@ import java.io.InputStream;
import java.io.StringReader;
import java.nio.charset.Charset;
import java.util.List;
import javax.xml.transform.Source;
import javax.xml.transform.stream.StreamSource;
@@ -33,6 +32,7 @@ import org.apache.commons.fileupload.RequestContext;
import org.apache.commons.fileupload.disk.DiskFileItemFactory;
import org.junit.Before;
import org.junit.Test;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.http.HttpEntity;

View File

@@ -17,13 +17,15 @@
package org.springframework.http.converter;
import java.io.IOException;
import static org.junit.Assert.*;
import org.junit.Test;
import org.springframework.http.HttpInputMessage;
import org.springframework.http.HttpOutputMessage;
import org.springframework.http.MediaType;
import static org.junit.Assert.*;
/**
* Test-case for AbstractHttpMessageConverter.
*

View File

@@ -16,13 +16,6 @@
package org.springframework.http.converter;
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import java.io.IOException;
import java.math.BigInteger;
import java.nio.charset.Charset;
@@ -31,6 +24,7 @@ import java.util.Locale;
import org.junit.Before;
import org.junit.Test;
import org.springframework.core.convert.ConversionService;
import org.springframework.core.convert.support.DefaultConversionService;
import org.springframework.core.io.Resource;
@@ -40,6 +34,8 @@ import org.springframework.http.server.ServletServerHttpResponse;
import org.springframework.mock.web.test.MockHttpServletRequest;
import org.springframework.mock.web.test.MockHttpServletResponse;
import static org.junit.Assert.*;
/**
* Test cases for {@link ObjectToStringHttpMessageConverter} class.
*

View File

@@ -21,6 +21,7 @@ import java.util.Arrays;
import org.junit.Before;
import org.junit.Test;
import org.springframework.core.io.ByteArrayResource;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;

View File

@@ -19,7 +19,6 @@ package org.springframework.http.converter;
import java.io.IOException;
import java.nio.charset.Charset;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
@@ -27,6 +26,8 @@ import org.springframework.http.MediaType;
import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import static org.junit.Assert.*;
/** @author Arjen Poutsma */
public class StringHttpMessageConverterTests {

View File

@@ -24,15 +24,15 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.google.gson.reflect.TypeToken;
import org.junit.Test;
import org.springframework.core.ParameterizedTypeReference;
import org.springframework.http.MediaType;
import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import org.springframework.http.converter.HttpMessageNotReadableException;
import com.google.gson.reflect.TypeToken;
import static org.junit.Assert.*;
/**

View File

@@ -28,13 +28,9 @@ import org.springframework.http.MockHttpOutputMessage;
import org.springframework.protobuf.Msg;
import org.springframework.protobuf.SecondMsg;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.*;
import static org.mockito.Matchers.anyObject;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.*;
/**

View File

@@ -16,14 +16,10 @@
package org.springframework.http.converter.xml;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import java.lang.reflect.Type;
import java.util.Collection;
import java.util.List;
import java.util.Set;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
@@ -32,11 +28,14 @@ import javax.xml.stream.XMLInputFactory;
import org.junit.Before;
import org.junit.Test;
import org.springframework.core.ParameterizedTypeReference;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.http.MockHttpInputMessage;
import static org.junit.Assert.*;
/**
* Test fixture for {@link Jaxb2CollectionHttpMessageConverter}.
*

View File

@@ -26,11 +26,6 @@ import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.adapters.XmlAdapter;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import static org.custommonkey.xmlunit.XMLAssert.*;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import org.junit.Before;
import org.junit.Test;
@@ -43,6 +38,11 @@ import org.springframework.http.MediaType;
import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import static org.custommonkey.xmlunit.XMLAssert.*;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
/**
* Tests for {@link Jaxb2RootElementHttpMessageConverter}.
*

View File

@@ -21,6 +21,8 @@ import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.nio.charset.Charset;
import com.fasterxml.jackson.annotation.JsonView;
import com.fasterxml.jackson.dataformat.xml.XmlMapper;
import org.junit.Test;
import org.springframework.http.HttpOutputMessage;
@@ -31,9 +33,6 @@ import org.springframework.http.converter.HttpMessageNotReadableException;
import org.springframework.http.converter.json.AbstractJackson2HttpMessageConverter;
import org.springframework.http.converter.json.MappingJacksonValue;
import com.fasterxml.jackson.annotation.JsonView;
import com.fasterxml.jackson.dataformat.xml.XmlMapper;
import static org.hamcrest.CoreMatchers.*;
import static org.junit.Assert.*;

View File

@@ -20,6 +20,7 @@ import javax.xml.transform.Result;
import javax.xml.transform.stream.StreamSource;
import org.junit.Test;
import org.springframework.beans.TypeMismatchException;
import org.springframework.http.MediaType;
import org.springframework.http.MockHttpInputMessage;

View File

@@ -16,14 +16,10 @@
package org.springframework.http.converter.xml;
import static org.custommonkey.xmlunit.XMLAssert.assertXMLEqual;
import static org.junit.Assert.*;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.StringReader;
import java.nio.charset.Charset;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.stream.XMLStreamReader;
import javax.xml.transform.Source;
@@ -34,6 +30,12 @@ import javax.xml.transform.stream.StreamSource;
import org.junit.Before;
import org.junit.Test;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import org.xml.sax.XMLReader;
import org.xml.sax.helpers.DefaultHandler;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
@@ -42,13 +44,10 @@ import org.springframework.http.MockHttpInputMessage;
import org.springframework.http.MockHttpOutputMessage;
import org.springframework.util.FileCopyUtils;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import org.xml.sax.XMLReader;
import org.xml.sax.helpers.DefaultHandler;
import static org.custommonkey.xmlunit.XMLAssert.*;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.*;
import static org.junit.Assert.assertTrue;
/**
* @author Arjen Poutsma

View File

@@ -21,7 +21,6 @@ import java.util.Arrays;
import java.util.Collections;
import java.util.Iterator;
import java.util.List;
import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;

View File

@@ -20,6 +20,7 @@ import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import org.springframework.util.Assert;
import org.springframework.util.FileCopyUtils;
import org.springframework.web.multipart.MultipartFile;

View File

@@ -22,7 +22,6 @@ import java.util.Collections;
import java.util.Enumeration;
import java.util.LinkedHashMap;
import java.util.Map;
import javax.el.ELContext;
import javax.servlet.Servlet;
import javax.servlet.ServletConfig;

View File

@@ -21,7 +21,6 @@ import java.io.IOException;
import java.io.InputStream;
import java.util.Collection;
import java.util.Collections;
import javax.servlet.http.Part;
import org.springframework.util.Assert;

View File

@@ -20,9 +20,9 @@ import com.caucho.burlap.client.BurlapProxyFactory;
import com.caucho.hessian.client.HessianProxyFactory;
import junit.framework.TestCase;
import org.springframework.remoting.RemoteAccessException;
import org.springframework.tests.sample.beans.ITestBean;
import org.springframework.tests.sample.beans.TestBean;
import org.springframework.remoting.RemoteAccessException;
/**
* @author Juergen Hoeller

View File

@@ -35,8 +35,6 @@ import javax.servlet.http.HttpServletResponse;
import junit.framework.TestCase;
import org.aopalliance.intercept.MethodInvocation;
import org.springframework.tests.sample.beans.ITestBean;
import org.springframework.tests.sample.beans.TestBean;
import org.springframework.beans.factory.BeanClassLoaderAware;
import org.springframework.mock.web.test.MockHttpServletRequest;
import org.springframework.mock.web.test.MockHttpServletResponse;
@@ -45,6 +43,8 @@ import org.springframework.remoting.support.DefaultRemoteInvocationExecutor;
import org.springframework.remoting.support.RemoteInvocation;
import org.springframework.remoting.support.RemoteInvocationFactory;
import org.springframework.remoting.support.RemoteInvocationResult;
import org.springframework.tests.sample.beans.ITestBean;
import org.springframework.tests.sample.beans.TestBean;
/**
* @author Juergen Hoeller

View File

@@ -18,7 +18,6 @@ package org.springframework.remoting.jaxws;
import java.net.MalformedURLException;
import java.net.URL;
import javax.xml.namespace.QName;
import javax.xml.ws.BindingProvider;
import javax.xml.ws.Service;
@@ -27,6 +26,7 @@ import javax.xml.ws.WebServiceRef;
import javax.xml.ws.soap.AddressingFeature;
import org.junit.Test;
import org.springframework.beans.factory.BeanCreationException;
import org.springframework.beans.factory.support.GenericBeanDefinition;
import org.springframework.beans.factory.support.RootBeanDefinition;

View File

@@ -15,8 +15,6 @@
*/
package org.springframework.web.accept;
import static org.junit.Assert.assertEquals;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
@@ -24,12 +22,15 @@ import java.util.Map;
import org.junit.Before;
import org.junit.Test;
import org.springframework.http.MediaType;
import org.springframework.mock.web.test.MockHttpServletRequest;
import org.springframework.web.HttpMediaTypeNotAcceptableException;
import org.springframework.web.context.request.NativeWebRequest;
import org.springframework.web.context.request.ServletWebRequest;
import static org.junit.Assert.*;
/**
* Test fixture for {@link ContentNegotiationManagerFactoryBean} tests.
* @author Rossen Stoyanchev

View File

@@ -15,18 +15,19 @@
*/
package org.springframework.web.accept;
import static org.junit.Assert.assertEquals;
import java.util.List;
import org.junit.Before;
import org.junit.Test;
import org.springframework.http.MediaType;
import org.springframework.mock.web.test.MockHttpServletRequest;
import org.springframework.web.HttpMediaTypeNotAcceptableException;
import org.springframework.web.context.request.NativeWebRequest;
import org.springframework.web.context.request.ServletWebRequest;
import static org.junit.Assert.*;
/**
* Test fixture for HeaderContentNegotiationStrategy tests.
*

Some files were not shown because too many files have changed in this diff Show More