The sample generates four APDU scripts that demonstrate the object deletion mechanism, applet deletion, and package deletion:
od1-1.scr
- Demonstrates the object deletion mechanism and verifies that memory for objects referenced from transient memory of type CLEAR_ON_DESELECT
is reclaimed after an applet is deselected.
od1-1.scr
does not depend on any other sample. The final state of cref
memory must be saved to a file for od1-2.scr
to use.
od1-2.scr
- Demonstrates the object deletion mechanism and verifies that memory for objects referenced from transient memory of type CLEAR_ON_RESET
is reclaimed after card reset.
The od1-2.scr
sample must be run after od1-1.scr
because the initial state of cref
must be the same as its final state after running od1-1.scr
. After running od1-2.scr
, the final state of cref
must be saved to a file so that od1-3.scr
can use it.
od1-3.scr
- Performs applet deletion, package deletion, and employs the AppletEvent.uninstall
method to uninstall an applet. The sample verifies that all transient memory of type CLEAR_ON_RESET
and CLEAR_ON_DESELECT
is returned to the memory manager. The sample also demonstrates the use of the AppletEvent.uninstall()
method.
The od1-3.scr
sample must be run after od1-2.scr
because the initial state of cref
must be the same as its final state after running od1-2.scr
.
od2.scr
- Demonstrates package deletion and checks that persistent memory is returned to the memory manager. This sample has one script, od2.scr
.
The simulator must be restarted before running each APDU script.
Follow one of these sets of instructions to run this sample: