twitter / Serial

Light-weight, fast framework for object serialization in Java, with Android support.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Using Serial for classes where you don't own the super class

tfrysinger opened this issue · comments

Reading through the description and attempting an initial test, it is unclear how I would use this to serialize a custom View or ViewGroup for example? When a super class that I don't own has properties, how would I get these properly serialized using this library - or is the intent of this library only for class hierarchies completely under the control of the developer?

What I'm actually trying to do is serialize the contents of my custom "SavedState" class that extends View.BaseSavedState - I have this working fine for saving/restoring state during configuration changes in the same app, but I also need to persist this state so I can transfer it to another instance of the app and re-create the View properly there.

After reading through a bit more posts and the code, I'm assuming the answer to my question is that "yes", one uses this library for classes where one has complete control - similar to how you would have to do it if you were implementing serialized instead. So I'm closing this issue.