public class PackagesCache extends java.lang.Object implements java.lang.Iterable<PackageInfo>
Constructor and Description |
---|
PackagesCache(InstallPackageProviderServices installerProviderServices) |
Modifier and Type | Method and Description |
---|---|
void |
addBundledPackage(PackageInfo pkg,
java.io.File bundleFile,
java.lang.String bundleEntryName) |
void |
addBundledPackageIndex(PackageInfo pkg,
java.io.File bundleFile,
java.lang.String bundleEntryName) |
void |
addPackage(PackageInfo pkg,
java.io.File f) |
void |
addPackageIndex(PackageInfo pkg) |
boolean |
contains(PackageInfo packageInfo) |
void |
download(PackageInfo packageInfo,
SimpleTaskStatus taskStatus) |
PackageInfo |
get(int n) |
java.io.File |
getFile(PackageInfo packageInfo)
Return the file associated to this package.
|
java.io.InputStream |
getInputStream(PackageInfo packageInfo)
Return the InputStream of the package.
|
boolean |
isDownloaded(PackageInfo packageInfo) |
java.util.Iterator<PackageInfo> |
iterator() |
int |
size() |
public PackagesCache(InstallPackageProviderServices installerProviderServices)
public void addPackage(PackageInfo pkg, java.io.File f)
public void addPackageIndex(PackageInfo pkg)
public void addBundledPackage(PackageInfo pkg, java.io.File bundleFile, java.lang.String bundleEntryName)
public void addBundledPackageIndex(PackageInfo pkg, java.io.File bundleFile, java.lang.String bundleEntryName)
public java.io.File getFile(PackageInfo packageInfo)
packageInfo
- public boolean contains(PackageInfo packageInfo)
public boolean isDownloaded(PackageInfo packageInfo)
public void download(PackageInfo packageInfo, SimpleTaskStatus taskStatus)
public java.io.InputStream getInputStream(PackageInfo packageInfo)
packageInfo
- public java.util.Iterator<PackageInfo> iterator()
iterator
in interface java.lang.Iterable<PackageInfo>
public int size()
public PackageInfo get(int n)