From the course: Dart Clean Code: Writing High-Efficiency, Maintainable Dart Programs
Unlock the full course today
Join today to access over 24,600 courses taught by industry experts.
Challenge: Create a customer class - Dart Tutorial
From the course: Dart Clean Code: Writing High-Efficiency, Maintainable Dart Programs
Challenge: Create a customer class
(upbeat music) - In this challenge, you will create a customer class that will perform a set of instructions. Your job is to ensure that your code adheres to that best practices as closely as possible. In the class, you will create a getter and a setter for the customer's first name, last name, and address. You will also create a function that displays the first name of a customer by concatenating the first name and last name. Finally, you will write an empty function that makes an API call to a server, and returns the idea of a customer. Remember to explore the different best practices we've discussed in this chapter, where applicable.