Vijayakumar Rengaraj

Greenhorn
+ Follow
since Jun 09, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Vijayakumar Rengaraj

Just tell me what are all the risks involved if my bean doesn't implement the Serializable interface?
14 years ago
JSP
Thanks for the reply.

My web application is running in one of the webservers. I just create a javaBean and set some values and put it in the request scope. In my JSP I just get the bean from the request scope and print the value... simple.

For this simple process whether my been need to implement the serializable interface. And what are all the risks involved if I didn't implement the Serializable interface. I heard that we need to implement serializable to avoid accessing/changing the data through the network. Is it true?

Thanks in advance.
14 years ago
JSP
I've a plain Java bean which I used as a model in the MVC architecture. My application is running in the remote server. In this situation whether my model should implement the Serializable Interface. If yes, what will be a error/exception if I failed to implement a Serializable interface?
14 years ago
JSP

Venu Babu Ravi wrote:In a Collection there are ten numbers from 1 to 10. After that i have retrived 9 numbers randomly.Can any one help me what is number avilable in the collection



Welcome to Javaranch

The content of the collection will not change with respect to the retrieval, You can get the elements of the collection based on the position(in case of List) any any time.
14 years ago
In between the two DB interactions you can close the resultset but not the statement object .

But it is not advisable to close the resultset and statement objects within try block.
you can try the below code:

finally{
if(rs!=null)
rs.close();
if(stmt!=null)
stmt.close();
}