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