public class SingleFileCodeBase extends java.lang.Object implements IScannableCodeBase
ICodeBase.Discovered
Constructor and Description |
---|
SingleFileCodeBase(ICodeBaseLocator codeBaseLocator,
java.lang.String fileName) |
Modifier and Type | Method and Description |
---|---|
void |
close()
This method should be called when done using the code base.
|
boolean |
containsSourceFiles()
Return whether or not this code base contains any source files.
|
ICodeBaseLocator |
getCodeBaseLocator()
Get the codebase locator describing the location of this codebase.
|
ICodeBase.Discovered |
getHowDiscovered()
Return how this codebase was discovered.
|
long |
getLastModifiedTime()
Get timestamp indicating the most recent time when any of the files in
the codebase were modified.
|
java.lang.String |
getPathName()
Get the filesystem pathname of this codebase.
|
boolean |
isApplicationCodeBase()
Return whether or not this codebase is an application codebase.
|
ICodeBaseIterator |
iterator()
Get an iterator over the resources in the this code base.
|
ICodeBaseEntry |
lookupResource(java.lang.String resourceName)
Look up a resource in this code base.
|
void |
setApplicationCodeBase(boolean isAppCodeBase)
Designate this code base as an application codebase.
|
void |
setHowDiscovered(ICodeBase.Discovered howDiscovered)
Set how this codebase was discovered.
|
void |
setLastModifiedTime(long lastModifiedTime)
Set timestamp indicating the most recent time when any of the files in
the codebase were modified.
|
java.lang.String |
toString() |
public SingleFileCodeBase(ICodeBaseLocator codeBaseLocator, java.lang.String fileName)
public java.lang.String toString()
toString
in class java.lang.Object
public ICodeBaseLocator getCodeBaseLocator()
ICodeBase
getCodeBaseLocator
in interface ICodeBase
public boolean containsSourceFiles() throws java.lang.InterruptedException
ICodeBase
containsSourceFiles
in interface ICodeBase
java.lang.InterruptedException
public ICodeBaseIterator iterator() throws java.lang.InterruptedException
IScannableCodeBase
iterator
in interface IScannableCodeBase
java.lang.InterruptedException
public ICodeBaseEntry lookupResource(java.lang.String resourceName)
ICodeBase
lookupResource
in interface ICodeBase
resourceName
- name of the resource to look uppublic void setApplicationCodeBase(boolean isAppCodeBase)
ICodeBase
setApplicationCodeBase
in interface ICodeBase
isAppCodeBase
- true if this is an application codebase, false if notpublic boolean isApplicationCodeBase()
ICodeBase
isApplicationCodeBase
in interface ICodeBase
public void setHowDiscovered(ICodeBase.Discovered howDiscovered)
ICodeBase
setHowDiscovered
in interface ICodeBase
howDiscovered
- one of the constants SPECIFIED, NESTED, IN_JAR_MANIFEST, or
IN_SYSTEM_CLASSPATHpublic ICodeBase.Discovered getHowDiscovered()
ICodeBase
getHowDiscovered
in interface ICodeBase
public void setLastModifiedTime(long lastModifiedTime)
ICodeBase
setLastModifiedTime
in interface ICodeBase
lastModifiedTime
- timestamp when any codebase files were most-recently modifiedpublic long getLastModifiedTime()
ICodeBase
getLastModifiedTime
in interface ICodeBase
public java.lang.String getPathName()
ICodeBase
getPathName
in interface ICodeBase
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.