public static class ClasspathStorage.ClasspathResolver extends Storage.PackageResolver
| Constructor and Description |
|---|
ClasspathResolver(java.lang.String pkg_root,
java.lang.String abbrev,
java.lang.String rsrc_name) |
| Modifier and Type | Method and Description |
|---|---|
java.net.URI |
getContentDirBaseURI()
The base URI of the package "content directory".
|
java.lang.String |
getResourceName() |
javax.xml.transform.stream.StreamSource |
resolveComponent(java.lang.String path)
Resolve a resource within the package "content directory".
|
javax.xml.transform.stream.StreamSource |
resolveResource(java.lang.String path)
Resolve a resource within the "package directory".
|
public ClasspathResolver(java.lang.String pkg_root,
java.lang.String abbrev,
java.lang.String rsrc_name)
throws PackageException
PackageExceptionpublic java.net.URI getContentDirBaseURI()
throws PackageException
Storage.PackageResolverURI.resolve(String) on the returned value, with a
relative filename, must resolve this filename in the installed package
"content directory".
Use with caution, especially on storages not on a (regular) file-system.getContentDirBaseURI in class Storage.PackageResolverPackageException - in case of any error. Also thrown by storage
implementations for which such a URI does not make sense.public java.lang.String getResourceName()
getResourceName in class Storage.PackageResolverpublic javax.xml.transform.stream.StreamSource resolveResource(java.lang.String path)
throws PackageException
Storage.PackageResolverresolveResource in class Storage.PackageResolverpath - The path to resolve, relative to the package directory.Source object.PackageException - in case of any other error.public javax.xml.transform.stream.StreamSource resolveComponent(java.lang.String path)
throws PackageException
Storage.PackageResolverresolveComponent in class Storage.PackageResolverpath - The path to resolve, relative to the package content
directory.Source object.PackageException - in case of any other error.Copyright © 2015-2023 EXPath. All Rights Reserved