Our Online Store have the new products: RFID antenna board. Currently it can work with JC10M24R and JCOP4 card chips.
Compared with normal cards, the antenna board module has a smaller size and fixed holes, which is easy to integrate in the IOT(Internet Of Things) project.

Is there a method which can handle the exception during the applet execution

JavaCard Applet Development Related Questions and Answers.
user143839285163098
Posts: 5
Joined: Fri Jul 31, 2015 9:34 pm
Points :13
Contact:

Is there a method which can handle the exception during the applet execution

Post by user143839285163098 » Wed Sep 23, 2015 4:13 am

I have finished an applet recently. Now I want to test the sturdiness of this applet.
I want to know if there is a method which can handle the exception during the applet execution.
It is just like

Code: Select all

try {
...
}
catch (Exception e) {
...
}

Any help is much appreciated.

User avatar
horse dream
Posts: 76
Joined: Thu May 21, 2015 11:48 pm
Points :138
Contact:

Re: Is there a method which can handle the exception during the applet execution

Post by horse dream » Thu Sep 24, 2015 2:26 am

Maybe you can use Transaction API.
Just like this

Code: Select all

    JCSystem.beginTransaction();
   
    // your operations  are between beginTransation() and commitTransation() 
   
    JCSystem.commitTransaction();


Note that if any exception happens before commitTransation() method, everything returns to its original states.

Post Reply Previous topicNext topic

Who is online

Users browsing this forum: No registered users and 53 guests

JavaCard OS : Disclaimer