File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes serialization Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "serialization" Watch "serialization" New topic


Rauhl Roy
Ranch Hand

Joined: Aug 01, 2006
Posts: 401


I have a class in which some methods are to be serialized and I don't want to serialze some of them. So what should I do.

As far as I know TRANSIENT is for varialbles only. But I do not know, by making a methods STATIC We can stop it from being serialized.

Ajay Singh
Ranch Hand

Joined: Dec 13, 2006
Posts: 182
methods are *never* serialized - the state of a object is preserved by saving the fields and their values.
I agree. Here's the link:
subject: serialization
It's not a secret anymore!