parent
7b1010cf61
commit
5a92aa4e06
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2002-2015 the original author or authors.
|
* Copyright 2002-2016 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -30,7 +30,7 @@ import org.springframework.util.StringUtils;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@link Resource} implementation for {@code java.io.File} handles.
|
* {@link Resource} implementation for {@code java.io.File} handles.
|
||||||
* Obviously supports resolution as File, and also as URL.
|
* Supports resolution as a {@code File} and also as a {@code URL}.
|
||||||
* Implements the extended {@link WritableResource} interface.
|
* Implements the extended {@link WritableResource} interface.
|
||||||
*
|
*
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
@ -85,7 +85,6 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||||
return this.path;
|
return this.path;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This implementation returns whether the underlying file exists.
|
* This implementation returns whether the underlying file exists.
|
||||||
* @see java.io.File#exists()
|
* @see java.io.File#exists()
|
||||||
|
|
|
@ -32,7 +32,7 @@ import org.springframework.util.StringUtils;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@link Resource} implementation for {@code java.net.URL} locators.
|
* {@link Resource} implementation for {@code java.net.URL} locators.
|
||||||
* <p>Supports resolution as a {@code URL} and also as a {@code File} in
|
* Supports resolution as a {@code URL} and also as a {@code File} in
|
||||||
* case of the {@code "file:"} protocol.
|
* case of the {@code "file:"} protocol.
|
||||||
*
|
*
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
@ -134,6 +134,7 @@ public class UrlResource extends AbstractFileResolvingResource {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determine a cleaned URL for the given original URL.
|
* Determine a cleaned URL for the given original URL.
|
||||||
* @param originalUrl the original URL
|
* @param originalUrl the original URL
|
||||||
|
@ -152,7 +153,6 @@ public class UrlResource extends AbstractFileResolvingResource {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This implementation opens an InputStream for the given URL.
|
* This implementation opens an InputStream for the given URL.
|
||||||
* <p>It sets the {@code useCaches} flag to {@code false},
|
* <p>It sets the {@code useCaches} flag to {@code false},
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2002-2015 the original author or authors.
|
* Copyright 2002-2016 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -56,16 +56,16 @@ public abstract class ClassUtils {
|
||||||
/** Prefix for internal non-primitive array class names: "[L" */
|
/** Prefix for internal non-primitive array class names: "[L" */
|
||||||
private static final String NON_PRIMITIVE_ARRAY_PREFIX = "[L";
|
private static final String NON_PRIMITIVE_ARRAY_PREFIX = "[L";
|
||||||
|
|
||||||
/** The package separator character '.' */
|
/** The package separator character: '.' */
|
||||||
private static final char PACKAGE_SEPARATOR = '.';
|
private static final char PACKAGE_SEPARATOR = '.';
|
||||||
|
|
||||||
/** The path separator character '/' */
|
/** The path separator character: '/' */
|
||||||
private static final char PATH_SEPARATOR = '/';
|
private static final char PATH_SEPARATOR = '/';
|
||||||
|
|
||||||
/** The inner class separator character '$' */
|
/** The inner class separator character: '$' */
|
||||||
private static final char INNER_CLASS_SEPARATOR = '$';
|
private static final char INNER_CLASS_SEPARATOR = '$';
|
||||||
|
|
||||||
/** The CGLIB class separator character "$$" */
|
/** The CGLIB class separator: "$$" */
|
||||||
public static final String CGLIB_CLASS_SEPARATOR = "$$";
|
public static final String CGLIB_CLASS_SEPARATOR = "$$";
|
||||||
|
|
||||||
/** The ".class" file suffix */
|
/** The ".class" file suffix */
|
||||||
|
|
|
@ -136,11 +136,7 @@ public class ServletWrappingController extends AbstractController
|
||||||
@Override
|
@Override
|
||||||
public void afterPropertiesSet() throws Exception {
|
public void afterPropertiesSet() throws Exception {
|
||||||
if (this.servletClass == null) {
|
if (this.servletClass == null) {
|
||||||
throw new IllegalArgumentException("servletClass is required");
|
throw new IllegalArgumentException("'servletClass' is required");
|
||||||
}
|
|
||||||
if (!Servlet.class.isAssignableFrom(this.servletClass)) {
|
|
||||||
throw new IllegalArgumentException("servletClass [" + this.servletClass.getName() +
|
|
||||||
"] needs to implement interface [javax.servlet.Servlet]");
|
|
||||||
}
|
}
|
||||||
if (this.servletName == null) {
|
if (this.servletName == null) {
|
||||||
this.servletName = this.beanName;
|
this.servletName = this.beanName;
|
||||||
|
|
Loading…
Reference in New Issue