Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / December 2005

Tip: Looking for answers? Try searching our database.

serial and Customiser Bean

Thread view: 
pcouas - 12 Dec 2005 18:29 GMT
Hi,

I have created an EditorBean and an Applet with some button, but when i
try to Serial it.
I have following error message ?
An idea ?

java.io.WriteAbortedException: writing aborted;
java.io.NotSerializableException: sun.awt.windows.WToolkit

Philippe
Thomas Fritsch - 12 Dec 2005 20:03 GMT
> I have created an EditorBean and an Applet with some button, but when i
> try to Serial it.
[quoted text clipped - 3 lines]
> java.io.WriteAbortedException: writing aborted;
> java.io.NotSerializableException: sun.awt.windows.WToolkit
This NotSerializableException is thrown because you tried to serialize an
object of type WToolkit. By default serialization writes out all non-static
and non-transient member variables. Therefore I would guess that you have a
member variable of type Toolkit declared somewhere in your class. The
solution would be to change your declaration from for example
   private Toolkit toolkit;
to
   private transient Toolkit toolkit;
Of course then you would have to set your toolkit variable during
deserialization in another way, probably in a readObject() method. For how
to declare and implement this method,  see
<http://java.sun.com/j2se/1.4.2/docs/api/java/io/Serializable.html> and
<http://java.sun.com/developer/technicalArticles/Programming/serialization/index.html>.

Signature

"TFritsch$t-online:de".replace(':','.').replace('$','@')

pcouas - 13 Dec 2005 07:31 GMT
Hi,

I use Dimension perhaps
pcouas - 13 Dec 2005 10:00 GMT
Yes i have an Toolkit, i see it in Serializable output file.
But it come in my Serializable output file only when  i press a
specific button for Viewing my own property Editor
I have declared my PropertyEditor like transient, but writeObject try
to serializable it ?

Regards
Philippe


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.