Class NestedZipFileCodeBaseLocator
- java.lang.Object
-
- edu.umd.cs.findbugs.classfile.impl.NestedZipFileCodeBaseLocator
-
- All Implemented Interfaces:
ICodeBaseLocator
public class NestedZipFileCodeBaseLocator extends java.lang.Object implements ICodeBaseLocator
Codebase locator for a zip/jar archive nested inside a parent codebase.- Author:
- David Hovemeyer
-
-
Constructor Summary
Constructors Constructor Description NestedZipFileCodeBaseLocator(ICodeBase parentCodeBase, java.lang.String resourceName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ICodeBaseLocatorcreateRelativeCodeBaseLocator(java.lang.String relativePath)Get the codebase locator describing the location of a relative codebase.booleanequals(java.lang.Object obj)ICodeBasegetParentCodeBase()java.lang.StringgetResourceName()inthashCode()ICodeBaseopenCodeBase()Get the codebase object.java.lang.StringtoString()Convert the codebase locator to a string representation.
-
-
-
Constructor Detail
-
NestedZipFileCodeBaseLocator
public NestedZipFileCodeBaseLocator(ICodeBase parentCodeBase, java.lang.String resourceName)
-
-
Method Detail
-
getParentCodeBase
public ICodeBase getParentCodeBase()
- Returns:
- Returns the parentCodeBase.
-
getResourceName
public java.lang.String getResourceName()
- Returns:
- Returns the resourceName.
-
createRelativeCodeBaseLocator
public ICodeBaseLocator createRelativeCodeBaseLocator(java.lang.String relativePath)
Description copied from interface:ICodeBaseLocatorGet the codebase locator describing the location of a relative codebase. This method is useful for getting the location of a codebase referred to in the Class-Path attribute of a Jar manifest.- Specified by:
createRelativeCodeBaseLocatorin interfaceICodeBaseLocator- Parameters:
relativePath- the path of a relative codebase- Returns:
- codebase locator of the relative codebase whose path is given
-
openCodeBase
public ICodeBase openCodeBase() throws ResourceNotFoundException, java.io.IOException
Description copied from interface:ICodeBaseLocatorGet the codebase object.- Specified by:
openCodeBasein interfaceICodeBaseLocator- Returns:
- the codebase object
- Throws:
ResourceNotFoundExceptionjava.io.IOException
-
toString
public java.lang.String toString()
Description copied from interface:ICodeBaseLocatorConvert the codebase locator to a string representation. If possible two codebase locators that refer to the same codebase should produce the same string representation. So, this string can serve as a key identifying the codebase in a map.- Specified by:
toStringin interfaceICodeBaseLocator- Overrides:
toStringin classjava.lang.Object- Returns:
- a string representation of the codebase
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-