public class ClasspathResourceLocator extends Object implements ContainerResourceLocator
Constructor and Description |
---|
ClasspathResourceLocator() |
Modifier and Type | Method and Description |
---|---|
URI |
getBaseURI()
Get the base URI for the locator instance.
|
InputStream |
getResource(String uri)
Get the stream specified by the 'uri' parameter.
|
InputStream |
getResource(String configName,
String defaultUri)
Get the resource specified by the container 'config' value.
|
public InputStream getResource(String configName, String defaultUri) throws IllegalArgumentException
ContainerResourceLocator
getResource
in interface ContainerResourceLocator
configName
- The container configuration entry name whose value specifies
the location of the resource.defaultUri
- The default location for the resource.IllegalArgumentException
- Illegal argument. Check the cause exception for more
information.public InputStream getResource(String uri) throws IllegalArgumentException
ExternalResourceLocator
getResource
in interface ExternalResourceLocator
uri
- The location of the resource to be located.IllegalArgumentException
- Illegal argument. Check the cause exception for more
information.public URI getBaseURI()
ContainerResourceLocator
getBaseURI
in interface ContainerResourceLocator
Copyright © 2020. All rights reserved.