org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl Class Reference

Inheritance diagram for org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl:

org.knopflerfish.framework.BundleStorage

List of all members.


Detailed Description

Storage of all bundles jar content.

Author:
Jan Stein

Mats-Ola Persson

Version:
Revision
1.1.1.1

Definition at line 48 of file file/BundleStorageImpl.java.


Public Member Functions

 BundleStorageImpl ()
 Create a container for all bundle data in this framework.
BundleArchive insertBundleJar (String location, InputStream is) throws Exception
 Insert bundle into persistent storage.
BundleArchive updateBundleArchive (BundleArchive old, InputStream is) throws Exception
 Insert a new jar file into persistent storagedata as an update to an existing bundle archive.
void replaceBundleArchive (BundleArchive oldBA, BundleArchive newBA) throws Exception
 Replace old bundle archive with a new updated bundle archive, that was created with updateBundleArchive.
BundleArchive[] getAllBundleArchives ()
 Get all bundle archive objects.
List getStartOnLaunchBundles ()
 Get all bundles tagged to start at next launch of framework.

Package Functions

boolean removeArchive (BundleArchive ba)
 Remove bundle archive from archives list.

Constructor & Destructor Documentation

org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.BundleStorageImpl (  ) 

Create a container for all bundle data in this framework.

Try to restore all saved bundle archive state.

Definition at line 70 of file file/BundleStorageImpl.java.

References org.knopflerfish.framework.FileTree.delete().


Member Function Documentation

BundleArchive org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.insertBundleJar ( String  location,
InputStream  is 
) throws Exception

Insert bundle into persistent storage.

Parameters:
location Location of bundle.
is Inputstrem with bundle content.
Returns:
Bundle archive object.

Implements org.knopflerfish.framework.BundleStorage.

Definition at line 122 of file file/BundleStorageImpl.java.

References org.knopflerfish.framework.FileTree.delete().

BundleArchive org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.updateBundleArchive ( BundleArchive  old,
InputStream  is 
) throws Exception

Insert a new jar file into persistent storagedata as an update to an existing bundle archive.

To commit this data a call to replaceBundleArchive is needed.

Parameters:
old BundleArchive to be replaced.
is Inputstrem with bundle content.
Returns:
Bundle archive object.

Implements org.knopflerfish.framework.BundleStorage.

Definition at line 152 of file file/BundleStorageImpl.java.

void org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.replaceBundleArchive ( BundleArchive  oldBA,
BundleArchive  newBA 
) throws Exception

Replace old bundle archive with a new updated bundle archive, that was created with updateBundleArchive.

Parameters:
oldBA BundleArchive to be replaced.
newBA Inputstrem with bundle content.
Returns:
New bundle archive object.

Implements org.knopflerfish.framework.BundleStorage.

Definition at line 167 of file file/BundleStorageImpl.java.

BundleArchive [] org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.getAllBundleArchives (  ) 

Get all bundle archive objects.

Returns:
Private array of all BundleArchives.

Implements org.knopflerfish.framework.BundleStorage.

Definition at line 187 of file file/BundleStorageImpl.java.

List org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.getStartOnLaunchBundles (  ) 

Get all bundles tagged to start at next launch of framework.

This list is sorted in increasing bundle id order.

Returns:
Private copy of a List with bundle id's.

Implements org.knopflerfish.framework.BundleStorage.

Definition at line 199 of file file/BundleStorageImpl.java.

References org.knopflerfish.framework.BundleArchive.getBundleLocation(), and org.knopflerfish.framework.BundleArchive.getStartOnLaunchFlag().

boolean org.knopflerfish.framework.bundlestorage.file.BundleStorageImpl.removeArchive ( BundleArchive  ba  )  [package]

Remove bundle archive from archives list.

Parameters:
id Bundle archive id to find.
Returns:
true if element was removed.

Definition at line 220 of file file/BundleStorageImpl.java.

References org.knopflerfish.framework.BundleArchive.getBundleId().


The documentation for this class was generated from the following file:
Generated on Mon Jan 11 21:19:19 2010 for OpenMobileIS by  doxygen 1.5.4