Kotlin has a powerful set of interfaces that let you manage dynamic data collections. These are categorized as Lists, Sets, and Maps. These interfaces are part of the kotlin.collections package, and can be used without any import statements.
- [Instructor] Kotlin has a powerful set of interfaces…that let you manage dynamic data collections.…These are categorized as lists, sets, and maps.…These interfaces are part of the Kotlin.collections package…and can be used without any import statements.…In this tip, I'm going to create a shopping cart collection.…It'll be a list, an ordered set of data.…Each item in the list will contain…an instance of a clothing item and a quantity.…The items priced will be part of a ClothingItem object.…
And then I'll be able to loop through the collection…and get a total value.…I already have one model class that I've named ClothingItem.…And as I showed in another tip, it's a sealed class.…ClothingItem is the super class…and it has sub-classes named Shirt and Pants.…When I create instances of this class,…I have to use the sub-classes.…The sealed class is abstract.…I'll need another data class for my shopping cart…and this new class will keep track of a single line item.…
I'll put it in my model package.…I'll create a new Kotlin file or class…
Skill Level Intermediate
Q: Why can't I earn a Certificate of Completion for this course?
A: We publish a new tutorial or tutorials for this course on a regular basis. We are unable to offer a Certificate of Completion because it is an ever-evolving course that is not designed to be completed. Check back often for new movies.
Android App Development: Data Persistence Librarieswith Annyce Davis4h 52m Intermediate
Building Android Apps with Cloud Serviceswith Albert Lo2h 37m Intermediate
1. Android Development Tips Weekly
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.