Developing Removable Packages

When a package is deleted, all of its code is removed from the card's memory. A package is eligible for deletion only if there are no dependencies on it, including:

  • Packages that are dependent on the package to be deleted

  • Applet instances or objects that either belong to the package, or that belong to a package that depends on the package to be deleted

Package deletion will not succeed if any of the following conditions exist:

  • A reachable instance of a class belonging to the package exists on the card.

  • Another package on the card depends on the package.

  • A reset or power failure occurs after the deletion process begins, but before it completes.

To ensure that a package can be easily removed from the card, avoid writing and downloading other packages that might be dependent on it. If other packages on the card depend on it, you must remove all dependent packages before you can remove this package from the card memory.