Path: csiph.com!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail From: Roedy Green Newsgroups: comp.lang.java.programmer Subject: Re: serialize spoilers Date: Thu, 25 Oct 2012 04:30:47 -0700 Organization: Canadian Mind Products Lines: 27 Message-ID: References: Reply-To: Roedy Green NNTP-Posting-Host: K2Qzzs3EAqXk5RLzfhxcSw.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: Forte Agent 6.00/32.1186 Xref: csiph.com comp.lang.java.programmer:19498 On Wed, 24 Oct 2012 14:05:00 -0700 (PDT), bob smith wrote, quoted or indirectly quoted someone who said : >What do you typically do when you want to serialize an object that doesn't naturally implement Serializable? If it is a built-in class, there is probably a good reason it is not Serializable. For example Images contain platform specific information, so you cannot save Images on one platform and reconstitute them on another. You can mark references transient, and restore them on your own somehow. You can look for some third party solution, or save them in some other format, e.g. images as PNG files. -- Roedy Green Canadian Mind Products http://mindprod.com There are four possible ways to poke a card into a slot. Nearly always, only one way works. To me that betrays a Fascist mentality, demanding customers conform to some arbitrary rule, and hassling them to discover the magic orientation. The polite way to do it is to design the reader slot so that all four ways work, or so that all the customer has to do is put the card in the vicinity of the reader.