Hi,
I stored an image using Storage.setValue. Now, I wanna check the size of this image. After reading some threads in this forum, I found JIM said using view memory is available. However I found nothing in this way. So is there any other method?
Hi,
I stored an image using Storage.setValue. Now, I wanna check the size of this image. After reading some threads in this forum, I found JIM said using view memory is available. However I found nothing in this way. So is there any other method?
If you're looking at how much memeory it takes when you load it, use
System.getSystemStats().freeMemory before you load and after, and look at the difference.
On devices with the Graphics Pool, it will have far less an impact on your apps memory. The f7 devices have a graphics pool.
JIM, my purpose is to see how many pictures I can persistent in Storage.I know the limit is 32kB totally, but don't know the size of the image processed and received by my device. I think there are under 10kB but not sure the accuracy value.
Try taking a typical one and keep saving it with different keys until you get an error
also, the way I read this is each key is limited to 32k. Not Storage in total: That varies by device
Values can also be of type Array or Dictionary containing the above listed types, excluding BitmapResource and AnimationResource. There is a limit on the size of the Object Store that can vary between devices. If you reach this limit, the value will not be saved and an exception will be thrown. Also, values are limited to 32 KB in size.
in runtime
It would be nice haha