class PathResourceLookupFunction extends java.lang.Object implements java.util.function.Function<ServerRequest,<any>>
RouterFunctions.resources(String, Resource)
.Modifier and Type | Field and Description |
---|---|
private Resource |
location |
private PathPattern |
pattern |
private static PathPatternParser |
PATTERN_PARSER |
Constructor and Description |
---|
PathResourceLookupFunction(java.lang.String pattern,
Resource location) |
Modifier and Type | Method and Description |
---|---|
<any> |
apply(ServerRequest request) |
private boolean |
isInvalidPath(java.lang.String path) |
private boolean |
isResourceUnderLocation(Resource resource) |
private java.lang.String |
processPath(java.lang.String path) |
java.lang.String |
toString() |
private static final PathPatternParser PATTERN_PARSER
private final PathPattern pattern
private final Resource location
public PathResourceLookupFunction(java.lang.String pattern, Resource location)
public <any> apply(ServerRequest request)
apply
in interface java.util.function.Function<ServerRequest,<any>>
private java.lang.String processPath(java.lang.String path)
private boolean isInvalidPath(java.lang.String path)
private boolean isResourceUnderLocation(Resource resource) throws java.io.IOException
java.io.IOException
public java.lang.String toString()
toString
in class java.lang.Object