HI ALL,
How to Overcome "OutOfMemoryException"? when I am compiling
source having more than 1000 LOC throwing this exception.
Can any one give correct answer to my question? thx

Answer Posted / sunit panday

actually there are some conditions due to which
OutOfMemoryException caused as follows:-
1. when java virtual machine coudnot create the object as
specified by the programmer
2. when the database so high as respect to system physical
and virtual memory is low
you can use following command to find the free memory:-
Runtime runtime = Runtime.getRuntime();
System.out.println ("Free memory : " - + runtime.freeMemory
() );
as this exception is in java.lang.Object package

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of jdbc?

582


When do we get java.sql.SQLException: No suitable driver found?

561


List the common jdbc exceptions ?

579


Why “no suitable driver” error occurs?

627


java based application for hospital management

3455






Give an example for execution of sql statement.

538


Why jdbc is used in java?

495


What is difference between odbc and jdbc?

516


What is jdbc in dbms?

510


Where can I find ojdbc14 jar file?

511


How does jdbc work?

515


What is a JDBC 2.0 DataSource?

574


Give a way to check that all result sets have bin accessed and update counts are generated by execute method.

488


How many locking systems are there in jdbc?

567


What is java soft framework?

563