public class LegacyClasspathResourceOrigin extends ClasspathResourceOrigin
ClasspathResourceOrigin
which exposes resources under the /mgnl-resources/ folder as if they were in the root.
See .ResourceOrigin.ResourceNotFoundException
Modifier and Type | Method and Description |
---|---|
protected URL |
getUrl(ClasspathResource resource) |
protected com.google.common.base.Predicate<String> |
resourcesFilter() |
protected String |
validatePath(String resource)
Verifies the given path is as-expected by this origin, and "prepares" it.
|
void |
watchForChanges(ResourceVisitor visitor)
LegacyClasspathResourceOrigin does not implement watching for resource changes, since there is nothing at all to observe there. |
classpathUrls, collectResources, createResourcesFor, doOpenStream, excludedPackages, excludedResourcesExtensions, excludedUrlExtensions, extensionsPattern, getByPath, getCharsetFor, getLastModified, getName, getParent, getPath, getRoot, hasPath, isDirectory, isFile, listChildren, newClasspathResource, observedResourcesPattern, urlsFilter
getName, isEditable, openReader, openStream, traverseWith
public void watchForChanges(ResourceVisitor visitor)
LegacyClasspathResourceOrigin
does not implement watching for resource changes, since there is nothing at all to observe there.
This will most likely ever contain only static web resources, and in particular no configuration file.watchForChanges
in interface ResourceOrigin<ClasspathResource>
watchForChanges
in class ClasspathResourceOrigin
ResourceVisitor
,
PredicatedResourceVisitor
protected com.google.common.base.Predicate<String> resourcesFilter()
resourcesFilter
in class ClasspathResourceOrigin
protected String validatePath(String resource)
ClasspathResourceOrigin
validatePath
in class ClasspathResourceOrigin
protected URL getUrl(ClasspathResource resource)
getUrl
in class ClasspathResourceOrigin
Copyright © 2003–2015 Magnolia International Ltd.. All rights reserved.