Alex Rivera | Logout

Does Java Serialization work for cyclic references?

Asked 2009-11-24T19:50:06.640
18

For example: Object A contains Object B that contains Object C that contains Object A.

Will Object A serialize properly?

Comment #9 here indicates that it does not work .

In contrast, XStream indicates that it does handle cyclic references.

Edit
Report

1 Answer

5

Yes, Java serialization works for circular references, read here for more information to help your understanding of what Java serialization can do.

answered 2009-11-24T20:04:15.813

Your Answer