}
break;
case EventTypes.NATIVE_MIDLET_GETINFO_REQUEST:
int isolateId = midlet.getIsolateId();
Isolate task = null;
Isolate[] allTasks = Isolate.getIsolates();
for (int i = 0; i < allTasks.length; i++) {
if (allTasks[i].id() == isolateId) {
task = allTasks[i];
break;
}
}
if (task != null) {
/* Structure to hold run time information about a midlet. */
RuntimeInfo runtimeInfo = new RuntimeInfo();
runtimeInfo.memoryTotal = task.totalMemory();
runtimeInfo.memoryReserved = task.reservedMemory();
runtimeInfo.usedMemory = task.usedMemory();
runtimeInfo.priority = task.getPriority();
// there is no Isolate API now
runtimeInfo.profileName = null;
saveRuntimeInfoInNative(runtimeInfo);
}