TtInformationControlViewModel
data class TtInformationControlViewModel(headImage: ImageDescriptor?, primaryTextArea: TtInformationControlViewModel.TextAreaViewModel, secondaryTextArea: TtInformationControlViewModel.TextAreaViewModel, tertiaryTextArea: TtInformationControlViewModel.TextAreaViewModel, onClick: () -> Unit?, ratingBarValue: Float?, ratingBarMaximumValue: Int, ratingBarText: StringResolver?, tailText: StringResolver?, tailIcon: DrawableResolver?, onTailSectionClick: () -> Unit?)
Content copied to clipboard
The ViewModel used to populate TtInformationControl.
A schematic overview of the information control:
_____________________________________________________________
| ______ | O Primary text | |
| | | | O Secondary text | ____ |
| | | | O Tertiary text | Tail text | | |
| |_____| | ***** Rating bar text | |___| |
|___________|____________________________|___________________|
Head Main Tail
section section sectionContent copied to clipboard
Constructors
Link copied to clipboard
fun TtInformationControlViewModel(headImage: ImageDescriptor? = null, primaryTextArea: TtInformationControlViewModel.TextAreaViewModel = TextAreaViewModel(), secondaryTextArea: TtInformationControlViewModel.TextAreaViewModel = TextAreaViewModel(), tertiaryTextArea: TtInformationControlViewModel.TextAreaViewModel = TextAreaViewModel(), onClick: () -> Unit? = null, ratingBarValue: Float? = null, ratingBarMaximumValue: Int = DEFAULT_RATING_BAR_MAXIMUM_VALUE, ratingBarText: StringResolver? = null, tailText: StringResolver? = null, tailIcon: DrawableResolver? = null, onTailSectionClick: () -> Unit? = null)
Content copied to clipboard
Types
Link copied to clipboard
data class TextAreaViewModel(text: StringResolver?, icon: DrawableResolver?)
Content copied to clipboard
ViewModel used to populate primaryTextArea, secondaryTextArea and tertiaryTextArea.
Properties
Link copied to clipboard
The maximum allowable value of ratingBarValue. The default value is DEFAULT_RATING_BAR_MAXIMUM_VALUE.
Link copied to clipboard
The value represents the current rating. This value should be between 0 and ratingBarMaximumValue. If the value is null, then the entire rating bar will be hidden.