Created
June 27, 2024 15:38
-
-
Save anitaa1990/63856c2d2af9b383def67e9dff82c7a7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data class ContactUiState( | |
val loading: Boolean = false, | |
val contacts: GroupedContacts = Collections.emptyMap() | |
) | |
/** | |
* Type aliases provide alternative names for existing types. | |
* If the type name is too long you can introduce a different shorter name | |
* and use the new one instead. In this example, we've created a typealias | |
* for `ContactModel` to convert it into a Map which includes the alphabets | |
* as the key and the list of `ContactModel` as the values of the Map. | |
*/ | |
typealias GroupedContacts = Map<String, List<ContactModel>> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment