onRestore not invoked for my custom BackupAgent

后端 未结 2 1477
情歌与酒
情歌与酒 2021-02-07 02:41

There are some data in my Android app that I would like to backup and restore. For that purpose I have created a custom implementation of BackupAgent.

In my

2条回答
  •  醉酒成梦
    2021-02-07 03:17

    In my experience, for some odd reason (which I have yet to identify), logging statements made in BackupAgents don't show up in the logs. Nonetheless, I have been able to confirm that the onRestore method is in fact properly run.

    In your question you indicate that the onRestore method "does not seem to be called" because you are unable to see the proper logs. Can you instead confirm that the result is failing (i.e. that data that should be properly restored isn't)?

提交回复
热议问题