Dart Classes and Constructs
In this chapter, we will look at object-oriented programming (OOP) and how this is supported by the Dart language. We will start by looking at the core principles of OOP concerning the Dart language, and then explore how to use OOP within Dart.
We will then take a deeper look at class definitions and how instances of a class are created, including an exploration of the constructor types available, which forms a key part of the way Flutter apps are coded. Additionally, we will look at how we store our code in files, and how to relate code from different files through imports.
Finally, we will look at some key Dart topics that are used throughout Flutter – generics and asynchronous programming. These are important concepts and knowledge of them will help with your understanding of the Flutter topics we will cover later in this book.
On completion of this chapter, you will have a solid foundational knowledge of Dart, which will set you in good...