Class TldResourcePath
java.lang.Object
org.apache.tomcat.util.descriptor.tld.TldResourcePath
A TLD Resource Path as defined in JSP 7.3.2.
 
This encapsulates references to Tag Library Descriptors that can be located in different places:
- As resources within an application
- As entries in JAR files included in the application
- As resources provided by the container
META-INF/taglib.tld. Such a mapping must be explicitly converted
 to a URL and entryName when using this implementation.- 
Constructor SummaryConstructorsConstructorDescriptionTldResourcePath(URL url, String webappPath) Constructor identifying a TLD resource directly.TldResourcePath(URL url, String webappPath, String entryName) Constructor identifying a TLD packaged within a JAR file.
- 
Method SummaryModifier and TypeMethodDescriptionbooleanReturns the name of the JAR entry that contains the TLD.getUrl()Returns the URL of the TLD or of the JAR containing the TLD.Returns the path within the web application, if any, that the resource returned bygetUrl()was obtained from.inthashCode()openJar()Opens a stream to access the TLD.Return the external form of the URL representing this TLD.
- 
Constructor Details- 
TldResourcePathConstructor identifying a TLD resource directly.- Parameters:
- url- the location of the TLD
- webappPath- the web application path, if any, of the TLD
 
- 
TldResourcePathConstructor identifying a TLD packaged within a JAR file.- Parameters:
- url- the location of the JAR
- webappPath- the web application path, if any, of the JAR
- entryName- the name of the entry in the JAR
 
 
- 
- 
Method Details- 
getUrlReturns the URL of the TLD or of the JAR containing the TLD.- Returns:
- the URL of the TLD
 
- 
getWebappPathReturns the path within the web application, if any, that the resource returned bygetUrl()was obtained from.- Returns:
- the web application path or @null if the the resource is not located within a web application
 
- 
getEntryNameReturns the name of the JAR entry that contains the TLD. May be null to indicate the URL refers directly to the TLD itself.- Returns:
- the name of the JAR entry that contains the TLD
 
- 
toExternalFormReturn the external form of the URL representing this TLD. This can be used as a canonical location for the TLD itself, for example, as the systemId to use when parsing its XML.- Returns:
- the external form of the URL representing this TLD
 
- 
openStreamOpens a stream to access the TLD.- Returns:
- a stream containing the TLD content
- Throws:
- IOException- if there was a problem opening the stream
 
- 
openJar- Throws:
- IOException
 
- 
equals
- 
hashCodepublic int hashCode()
 
-