In order to thank you for all members' support of our website, we are holding new events - Getting Free Samples by Paying Freight only.
Want to get free samples? Please check this post for more details.

How to store java primitive types contents in RAM

Communication

Moderator: UNKNwYSHSA

Diorin
Posts: 17
Joined: Thu Nov 26, 2015 4:08 am
Points :137
Contact:

How to store java primitive types contents in RAM

Post by Diorin » Mon Mar 07, 2016 4:25 am

I have finished some java classes which contains some java primitive types(e.g. short, boolean). Because these contents are stored in EEPROM, it slows down my applet. I want to know how to store these contents in RAM in order to speed up my applet.

popmun09
Posts: 36
Joined: Tue Feb 16, 2016 9:49 pm
Points :226
Contact:

Re: How to store java primitive types contents in RAM

Post by popmun09 » Wed Mar 16, 2016 5:00 am

In order to store volatile objects, you can put the attributes in a transient array.
There is support for different types, e.g. boolean, byte and short.
The usual technique is to map values in a single transient byte array.

See the documentation about makeTransientByteArray in the JCSytem class.

Post Reply Previous topicNext topic

Who is online

Users browsing this forum: No registered users and 1 guest

JavaCard OS : Disclaimer