In Android if I have information I want to persist across sessions I know I can use SharedPreferences or create a SQLite database or even write a file to the device and read it in later.
Is there a way to save and restore data like this just using Flutter? Or would I need to write device-specific code for Android and iOS like in the services example?
There are a few options:
You can use shared preferences from flutter's official plugins. https://github.com/flutter/plugins/tree/master/packages/shared_preferences
It uses Shared Preferences for Android, NSUserDefaults for iOS.
If you are in a situation where you wanna save a small value that you wanna refer later. then you should store your data as key-value data using shared_preferences
but if you want to store large data you should go with SQLITE
however you can always use firebase database which is available offline
Since we are talking about local storage you can always read and write files to the disk
Other solutions :
I think If you are going to store large amount of data in local storage you can use sqflite library. It is very easy to setup and I have personally used for some test project and it works fine.
https://github.com/tekartik/sqflite This a tutorial - https://proandroiddev.com/flutter-bookshelf-app-part-2-personal-notes-and-database-integration-a3b47a84c57
If you want to store data in cloud you can use firebase. It is solid service provide by google.
https://firebase.google.com/docs/flutter/setup