BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 05-30-2005, 03:14 AM   #1
rimzim
Knows Where the Search Button Is
 
Join Date: Jan 2005
Location: MAH
Posts: 38
Default How to count Object handles?

Please Login to Remove!

Hi all,

Im writing data in persistent storage. How can I check it out that how much object handles are being consumed. I know about the Memory & MemoryStats classes & even Honestly, I had tried the same. However, I could not make it out properly that how much object handles are available now.
Can anybody help me in,
Q1. What is the relation between all kinds of Memories like Flash, Persistent, Transient, RAM.
Q2. Somewhere I read that for 32mb Flash, there could be 65,000 Persistent Object handles, like for 7100t, but I found no function among these (Memory & MemoryStats) which gives me such number.
Q3. What is the difference between Persistent Object handles & Object handles?

Please clarify these points & provide me the way (or proper classes/functions) to calculate the free memory & avaialable Persistent object handles.

Thanx in advance.

RimZim.
Offline  
Old 05-30-2005, 08:23 AM   #2
arconsulting
Thumbs Must Hurt
 
Join Date: Aug 2004
Location: Metro NYC
Posts: 175
Default

To view the state of memory, set a breakpoint in your app and run it. When you hit the breakpoint, select "Memory Statistics" from the "View" menu and click "Refresh".

Persistent memory is used for storage of objects that can persist from one running of the app to another. Or are available after you turn off the device. Persistent memory is stored in Flash.

Transient memory is lost after you exit the app and is stored in RAM.

Flash is much slower than RAM.

Each object stored in persistent memory consumes a handle. So, a vector of 10 objects will consume 11 persistent object handles (1 + 10). A 32MB device is limited to about 65,000 persistent object handles. In some cases, you may run out of persistent object handles well before you run out of memory.

"Object handles" are similar but are for transient objects.
__________________
-- Aric Rosenbaum
BlackBerry consulting, BlackBerry development
www.arconsultinginc.com
BlackBerry consulting and development (RIM SI Partner)
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Vintage Apple Computer 4” Paper Cube Notepad Macintosh 80s 90s Office White picture

Vintage Apple Computer 4” Paper Cube Notepad Macintosh 80s 90s Office White

$39.95



Apple 1 Replica IC's: Vintage IC’s Many Types See List NOS 74XXX Types - Apple I picture

Apple 1 Replica IC's: Vintage IC’s Many Types See List NOS 74XXX Types - Apple I

$20.00



Vintage Post-it Note Pad Apple Magnetic Holder Pince A Notes Unused 1988 NOS picture

Vintage Post-it Note Pad Apple Magnetic Holder Pince A Notes Unused 1988 NOS

$11.89



VINTAGE COLLECTIBLE IBM APPLE POWERPC MICROPROCESSOR CHIP 343S1174-03 picture

VINTAGE COLLECTIBLE IBM APPLE POWERPC MICROPROCESSOR CHIP 343S1174-03

$9.99



Lot of 6 Vintage Apple Drawstring Bags For iPhone, Mac, Apple Watch, iPod picture

Lot of 6 Vintage Apple Drawstring Bags For iPhone, Mac, Apple Watch, iPod

$45.00



Vintage  Rainbow Logo Apple Post-It Sticky Notes 4

Vintage Rainbow Logo Apple Post-It Sticky Notes 4" Rare computer collectible

$39.99







Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.