Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Saving/Restoring history and persistant storage #97

Closed
Lakedaemon opened this issue Jun 27, 2015 · 1 comment
Closed

Saving/Restoring history and persistant storage #97

Lakedaemon opened this issue Jun 27, 2015 · 1 comment

Comments

@Lakedaemon
Copy link

It looks to me like History instances can be serialized and unserialized to parcels/bundles but not to String, which is surprising because IMO saving/restoring History to persistant storage should be a pretty common need (say, you want users to be able to find the app in the same state it was before a power down/a previous session)

In addition of StateParceler, Paths could optionaly implement
public interface StateToString {
String wrap(Object instance);
Object unwrap(String sring);
}
which would allow the implementation of 2 utillity methods to serialize/deserialize from String

Also, Gson should already be able to serialize/deserialize simple paths...but those utility methods aren't implemented in the GsonParceler

mmmhhh iterate the History and serialize each entry as an Object...and deserialize a list of Object into an History with a builder

@loganj
Copy link
Collaborator

loganj commented Feb 8, 2016

This seems hypothetical and a bit out of scope. Please reopen if you have a concrete need for this capability.

@loganj loganj closed this as completed Feb 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants