Reading and Writing Data and Files with Path Provider using Dart's Flutter Framework
What Will I Learn?
- You will learn how to use the path provider plugin in a flutter application
- You will learn how to use a future builder widget
- You will learn how to use the require meta keyword
- You will learn how to read and write data into a small file store on android or iOS
Requirements
- IDEA intellij or Visual Studio Code with the Dart/Flutter Plugins
- The Dart SDK and the Flutter SDK
- A fair understanding of Mobile development and Imperative or Object Oriented Programming
Difficulty
- Intermediate
Description
In this flutter video tutorial, we take a look at Google's path provider plugin. We also look at future builder widgets as well as asynchronous snapshots and we talk about how we can read and write data into files using flutter. We touch briefly on some of the meta programming keywords that are a part of the flutter framework, such as the @required
keyword.
Path provider gives us a platform agnostic method for accessing common file system locations on the devices that we are targeting. This includes the temporary folders, the documents folders and the external documents directories. This is useful because it makes it easier to create file caches and databases for our applications which will work properly on many different platforms without issue.
Future builders are widgets that let us change the look and feel of a widget based on the state of a future value. Future values are asynchronous which makes it important for us to have a method to check their state to defer the creation of a widget in our tree. We are able to use the asyncsnapshot type to check the current state of our future and then resolve the widget based on that state.
The source code for this project can be found here
Video Tutorial
Curriculum
- Dart Flutter Cross Platform Chat Application Tutorial
- Building a Multi-Page Application with Dart's Flutter Mobile Framework
- Making Http requests and Using Json in Dart's Flutter Framework
- Building Dynamic Lists with Streams in Dart's Flutter Framework
- Using GridView, Tabs, and Steppers in Dart's Flutter Framework
- Using Global Keys to get State and Validate Input in Dart's Flutter Framework
- The Basics of Animation with Dart's Flutter Framework
- Advanced Physics Based Animations in Dart's Flutter Framework
- Building a Drag and Drop Application with Dart's Flutter Framework
- Building a Hero Animation and an Application Drawer in Dart's Flutter Framework
- Building a Temperature Conversion Application using Dart's Flutter Framework
- Using Inherited Widgets and Gesture Detectors in Dart's Flutter Framework
- Using Gradients, Fractional Offsets, Page Views and Other Widgets in Dart's Flutter Framework
- Building a Calculator Layout using Dart's Flutter Framework
- Finishing our Calculator Application with Dart's Flutter Framework
- Making use of Shared Preferences, Flex Widgets and Dismissibles with Dart's Flutter framework
- Using the Different Style Widgets and Properties in Dart's Flutter Framework
- Composing Animations and Chaining Animations in Dart's Flutter Framework
- Building a Countdown Timer with a Custom Painter and Animations in Dart's Flutter Framework
Posted on Utopian.io - Rewarding Open Source Contributors
Thank you for the contribution. It has been approved.
Very fine video tutorial, @tensor. I appreciate your concise delivery of the instructions. The pace is easy to follow and clear.
One minor suggestion that you can consider:
Great work @tensor. I appreciate your educationally sound approach to these lesson.
Cheers,
buckydurddle
You can contact us on Discord.
[utopian-moderator]
I do appreciate the suggestion and I would do something like this if I had the time and means to do so.
YouTube removed their annotation features about a year ago. This means that unfortunately, I can't put small text annotations into a video after uploading it anymore. It only allows you to put in either a closing screen or 4 boxes which can only be links to other videos and playlists etc. This has been a source of frustration for me because all of my videos are live coded and as such there are times when I do make mistakes (and it would be nice if I could just place some text on the screen.).
The other way to do this would be for me to prepare some content beforehand to add into the video either through editing or during recording. I simply do not have the time to do this right now. I have occasionally made some small on-the-fly visual aids with paint or word but those aren't great. I really wish I had more time to move towards making power point presentations and stuff like that to accompany my videos but I would need a much larger following to justify that kind of work.
Unfortunately, as it stands, I still have to make a living as a developer which means working a normal work day. In the year, I have been looking for a way that might let me devote more time to the production value of my videos but I still can't quite get there yet.
Thank you for moderating my contribution and giving me some constructive criticism; I truly appreciate it.
I completely understand @tensor. Life is a juggling act.
I wonder if it would be useful for contributors if I was to create some workflow ideas to help streamline the creation process. Perhaps suggest some tips and tricks that could help reduce the production time and incorporate some engaging techniques at the same time. I notice you use OBS. Perhaps some text overlay ideas. Somethings that contributors like yourself could consider incorporating if that resonate with you. hmmm. I will think about this more.
In the meantime, keep up the great work.
Cheers,
BuckyDurddle
That does sound like a good idea. Given that you probably have been using YouTube longer then most of the people on this platform (myself included) you probably have a bunch of good advice laying around on the technical aspects of making videos and "selling" content to an audience.
I've already put you on my feed, so Ill keep an eye out if you do plan to start making this kind of content.
Thank you for your time.
Hey @buckydurddle, I just gave you a tip for your hard work on moderation. Upvote this comment to support the utopian moderators and increase your future rewards!
Hey @tensor I am @utopian-io. I have just upvoted you!
Achievements
Community-Driven Witness!
I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!
Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x