Replace space indentation with tabs
Issue: SPR-10127
This commit is contained in:
committed by
Chris Beams
parent
1762157ad1
commit
2cf45bad86
@@ -229,7 +229,7 @@ public abstract class HttpServletBean extends HttpServlet
|
||||
* @throws ServletException if any required properties are missing
|
||||
*/
|
||||
public ServletConfigPropertyValues(ServletConfig config, Set<String> requiredProperties)
|
||||
throws ServletException {
|
||||
throws ServletException {
|
||||
|
||||
Set<String> missingProps = (requiredProperties != null && !requiredProperties.isEmpty()) ?
|
||||
new HashSet<String>(requiredProperties) : null;
|
||||
@@ -247,9 +247,9 @@ public abstract class HttpServletBean extends HttpServlet
|
||||
// Fail if we are still missing properties.
|
||||
if (missingProps != null && missingProps.size() > 0) {
|
||||
throw new ServletException(
|
||||
"Initialization from ServletConfig for servlet '" + config.getServletName() +
|
||||
"' failed; the following required properties were missing: " +
|
||||
StringUtils.collectionToDelimitedString(missingProps, ", "));
|
||||
"Initialization from ServletConfig for servlet '" + config.getServletName() +
|
||||
"' failed; the following required properties were missing: " +
|
||||
StringUtils.collectionToDelimitedString(missingProps, ", "));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -191,7 +191,7 @@ public class ResourceServlet extends HttpServletBean {
|
||||
*/
|
||||
@Override
|
||||
protected final void doGet(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException {
|
||||
throws ServletException, IOException {
|
||||
|
||||
// determine URL of resource to include
|
||||
String resourceUrl = determineResourceUrl(request);
|
||||
@@ -247,7 +247,7 @@ public class ResourceServlet extends HttpServletBean {
|
||||
* @throws IOException if thrown by the RequestDispatcher
|
||||
*/
|
||||
private boolean includeDefaultUrl(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException {
|
||||
throws ServletException, IOException {
|
||||
|
||||
if (this.defaultUrl == null) {
|
||||
return false;
|
||||
@@ -265,13 +265,13 @@ public class ResourceServlet extends HttpServletBean {
|
||||
* @throws IOException if thrown by the RequestDispatcher
|
||||
*/
|
||||
private void doInclude(HttpServletRequest request, HttpServletResponse response, String resourceUrl)
|
||||
throws ServletException, IOException {
|
||||
throws ServletException, IOException {
|
||||
|
||||
if (this.contentType != null) {
|
||||
response.setContentType(this.contentType);
|
||||
}
|
||||
String[] resourceUrls =
|
||||
StringUtils.tokenizeToStringArray(resourceUrl, RESOURCE_URL_DELIMITERS);
|
||||
StringUtils.tokenizeToStringArray(resourceUrl, RESOURCE_URL_DELIMITERS);
|
||||
for (int i = 0; i < resourceUrls.length; i++) {
|
||||
// check whether URL matches allowed resources
|
||||
if (this.allowedResources != null && !this.pathMatcher.match(this.allowedResources, resourceUrls[i])) {
|
||||
|
||||
@@ -57,7 +57,7 @@ class ResourcesBeanDefinitionParser implements BeanDefinitionParser {
|
||||
String resourceRequestPath = element.getAttribute("mapping");
|
||||
if (!StringUtils.hasText(resourceRequestPath)) {
|
||||
parserContext.getReaderContext().error("The 'mapping' attribute is required.", parserContext.extractSource(element));
|
||||
return null;
|
||||
return null;
|
||||
}
|
||||
urlMap.put(resourceRequestPath, resourceHandlerName);
|
||||
|
||||
@@ -85,7 +85,7 @@ class ResourcesBeanDefinitionParser implements BeanDefinitionParser {
|
||||
String locationAttr = element.getAttribute("location");
|
||||
if (!StringUtils.hasText(locationAttr)) {
|
||||
parserContext.getReaderContext().error("The 'location' attribute is required.", parserContext.extractSource(element));
|
||||
return null;
|
||||
return null;
|
||||
}
|
||||
|
||||
ManagedList<String> locations = new ManagedList<String>();
|
||||
|
||||
@@ -35,7 +35,7 @@ public abstract class HandlerInterceptorAdapter implements AsyncHandlerIntercept
|
||||
* This implementation always returns <code>true</code>.
|
||||
*/
|
||||
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -226,7 +226,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
*/
|
||||
@Override
|
||||
protected final void onBindAndValidate(HttpServletRequest request, Object command, BindException errors)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
onBindAndValidate(request, command, errors, getCurrentPage(request));
|
||||
}
|
||||
@@ -248,7 +248,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
* @see org.springframework.validation.Errors
|
||||
*/
|
||||
protected void onBindAndValidate(HttpServletRequest request, Object command, BindException errors, int page)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -266,7 +266,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
*/
|
||||
@Override
|
||||
protected final Map referenceData(HttpServletRequest request, Object command, Errors errors)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
return referenceData(request, command, errors, getCurrentPage(request));
|
||||
}
|
||||
@@ -286,7 +286,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
* @see ModelAndView
|
||||
*/
|
||||
protected Map referenceData(HttpServletRequest request, Object command, Errors errors, int page)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
return referenceData(request, page);
|
||||
}
|
||||
@@ -315,7 +315,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
@Override
|
||||
protected ModelAndView showForm(
|
||||
HttpServletRequest request, HttpServletResponse response, BindException errors)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
return showPage(request, errors, getInitialPage(request, errors.getTarget()));
|
||||
}
|
||||
@@ -331,7 +331,7 @@ public abstract class AbstractWizardFormController extends AbstractFormControlle
|
||||
* @throws Exception in case of invalid state or arguments
|
||||
*/
|
||||
protected final ModelAndView showPage(HttpServletRequest request, BindException errors, int page)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
if (page >= 0 && page < getPageCount(request, errors.getTarget())) {
|
||||
if (logger.isDebugEnabled()) {
|
||||
|
||||
@@ -434,7 +434,7 @@ public abstract class BaseCommandController extends AbstractController {
|
||||
* @see #initBinder
|
||||
*/
|
||||
protected ServletRequestDataBinder createBinder(HttpServletRequest request, Object command)
|
||||
throws Exception {
|
||||
throws Exception {
|
||||
|
||||
ServletRequestDataBinder binder = new ServletRequestDataBinder(command, getCommandName());
|
||||
prepareBinder(binder);
|
||||
|
||||
@@ -138,7 +138,7 @@ public class WebContentInterceptor extends WebContentGenerator implements Handle
|
||||
|
||||
|
||||
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
|
||||
throws ServletException {
|
||||
throws ServletException {
|
||||
|
||||
String lookupPath = this.urlPathHelper.getLookupPathForRequest(request);
|
||||
if (logger.isDebugEnabled()) {
|
||||
|
||||
@@ -500,7 +500,7 @@ public class AnnotationMethodHandlerAdapter extends WebContentGenerator
|
||||
* @return the HttpInputMessage instance to use
|
||||
* @throws Exception in case of errors
|
||||
*/
|
||||
protected HttpInputMessage createHttpInputMessage(HttpServletRequest servletRequest) throws Exception {
|
||||
protected HttpInputMessage createHttpInputMessage(HttpServletRequest servletRequest) throws Exception {
|
||||
return new ServletServerHttpRequest(servletRequest);
|
||||
}
|
||||
|
||||
@@ -512,7 +512,7 @@ public class AnnotationMethodHandlerAdapter extends WebContentGenerator
|
||||
* @return the HttpInputMessage instance to use
|
||||
* @throws Exception in case of errors
|
||||
*/
|
||||
protected HttpOutputMessage createHttpOutputMessage(HttpServletResponse servletResponse) throws Exception {
|
||||
protected HttpOutputMessage createHttpOutputMessage(HttpServletResponse servletResponse) throws Exception {
|
||||
return new ServletServerHttpResponse(servletResponse);
|
||||
}
|
||||
|
||||
@@ -803,7 +803,7 @@ public class AnnotationMethodHandlerAdapter extends WebContentGenerator
|
||||
return AnnotationMethodHandlerAdapter.this.createHttpInputMessage(servletRequest);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Override
|
||||
protected HttpOutputMessage createHttpOutputMessage(NativeWebRequest webRequest) throws Exception {
|
||||
HttpServletResponse servletResponse = (HttpServletResponse) webRequest.getNativeResponse();
|
||||
return AnnotationMethodHandlerAdapter.this.createHttpOutputMessage(servletResponse);
|
||||
|
||||
@@ -82,8 +82,8 @@ public abstract class AbstractMessageConverterMethodProcessor extends AbstractMe
|
||||
* {@link #writeWithMessageConverters(Object, MethodParameter, ServletServerHttpRequest, ServletServerHttpResponse)}
|
||||
*/
|
||||
protected <T> void writeWithMessageConverters(T returnValue,
|
||||
MethodParameter returnType,
|
||||
NativeWebRequest webRequest)
|
||||
MethodParameter returnType,
|
||||
NativeWebRequest webRequest)
|
||||
throws IOException, HttpMediaTypeNotAcceptableException {
|
||||
ServletServerHttpRequest inputMessage = createInputMessage(webRequest);
|
||||
ServletServerHttpResponse outputMessage = createOutputMessage(webRequest);
|
||||
@@ -103,9 +103,9 @@ public abstract class AbstractMessageConverterMethodProcessor extends AbstractMe
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
protected <T> void writeWithMessageConverters(T returnValue,
|
||||
MethodParameter returnType,
|
||||
ServletServerHttpRequest inputMessage,
|
||||
ServletServerHttpResponse outputMessage)
|
||||
MethodParameter returnType,
|
||||
ServletServerHttpRequest inputMessage,
|
||||
ServletServerHttpResponse outputMessage)
|
||||
throws IOException, HttpMediaTypeNotAcceptableException {
|
||||
|
||||
Class<?> returnValueClass = returnValue.getClass();
|
||||
@@ -173,11 +173,11 @@ public abstract class AbstractMessageConverterMethodProcessor extends AbstractMe
|
||||
}
|
||||
else if (!allSupportedMediaTypes.isEmpty()) {
|
||||
List<MediaType> result = new ArrayList<MediaType>();
|
||||
for (HttpMessageConverter<?> converter : messageConverters) {
|
||||
if (converter.canWrite(returnValueClass, null)) {
|
||||
result.addAll(converter.getSupportedMediaTypes());
|
||||
}
|
||||
}
|
||||
for (HttpMessageConverter<?> converter : messageConverters) {
|
||||
if (converter.canWrite(returnValueClass, null)) {
|
||||
result.addAll(converter.getSupportedMediaTypes());
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
else {
|
||||
@@ -199,4 +199,4 @@ public abstract class AbstractMessageConverterMethodProcessor extends AbstractMe
|
||||
return MediaType.SPECIFICITY_COMPARATOR.compare(acceptType, produceType) <= 0 ? acceptType : produceType;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ public abstract class RequestContextUtils {
|
||||
* @throws IllegalStateException if no servlet-specific context has been found
|
||||
*/
|
||||
public static WebApplicationContext getWebApplicationContext(ServletRequest request)
|
||||
throws IllegalStateException {
|
||||
throws IllegalStateException {
|
||||
|
||||
return getWebApplicationContext(request, null);
|
||||
}
|
||||
|
||||
@@ -117,14 +117,14 @@ public class ButtonTag extends AbstractHtmlElementTag {
|
||||
tagWriter.writeAttribute("value", processFieldValue(getName(), valueToUse, getType()));
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the default value.
|
||||
*
|
||||
* @return The default value if none supplied.
|
||||
*/
|
||||
protected String getDefaultValue() {
|
||||
return "Submit";
|
||||
}
|
||||
/**
|
||||
* Return the default value.
|
||||
*
|
||||
* @return The default value if none supplied.
|
||||
*/
|
||||
protected String getDefaultValue() {
|
||||
return "Submit";
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the value of the '<code>type</code>' attribute. Subclasses
|
||||
|
||||
Reference in New Issue
Block a user