Showing posts with the label java Serializable

Java Keywords (Part XXIII): transient

Java keyword list abstract continue for new switch assert default goto * package synchronized boolean do if private this break double implements protected throw byte else import public throws case enum instanceof return transient catch extends int short try char final interface static void class finally long strictfp volatile const * float native super while Keyword marked with an asterisk (*) are keywords that, although valid, are not used by programmers. Before getting on how to use transient , you must understand why you need to use it. And for that, you must understand the concept of serialization in Java. Serialization is simply the mechanism provided by the language to turn an instance of an object into a byte stream, so that it can be sent over the wire. Remember, objects encapsulate data. So serialization is basically creating a byte array to transmit the object's data. But