Join us on the livestream at Android Dev Summit on 7-8 November 2018, starting at 10AM PDT!

RangeBuilder

open class RangeBuilder : TemplateSliceBuilder
kotlin.Any
   ↳ androidx.slice.builders.TemplateSliceBuilder
   ↳ androidx.slice.builders.ListBuilder.RangeBuilder

Builder to construct a range row which can be added to a ListBuilder.

A range row supports displaying a horizontal progress indicator.

Summary

Public constructors

Builder to construct a range row which can be added to a ListBuilder.

Public methods
open ListBuilder.RangeBuilder
setValue(value: Int)

Set the current value of the range.

open ListBuilder.RangeBuilder
setMax(max: Int)

Set the upper limit of the range.

open ListBuilder.RangeBuilder

Set the title.

open ListBuilder.RangeBuilder

Sets the content description.

open ListBuilder.RangeBuilder

Set the primary action for this row.

open ListBuilder.RangeBuilder

Set the subtitle.

Inherited functions

Public constructors

<init>

RangeBuilder(parent: ListBuilder)

Builder to construct a range row which can be added to a ListBuilder.

A range row supports displaying a horizontal progress indicator.

Public methods

setValue

open fun setValue(value: Int): ListBuilder.RangeBuilder

Set the current value of the range.

setMax

open fun setMax(max: Int): ListBuilder.RangeBuilder

Set the upper limit of the range. The default is 100.

setTitle

open fun setTitle(title: CharSequence): ListBuilder.RangeBuilder

Set the title.

setContentDescription

open fun setContentDescription(description: CharSequence): ListBuilder.RangeBuilder

Sets the content description.

setPrimaryAction

open fun setPrimaryAction(action: SliceAction): ListBuilder.RangeBuilder

Set the primary action for this row.

The action specified here will be sent when the whole row is clicked. If this is the first row in a ListBuilder this action will also be used to define the androidx.slice.widget.SliceView#MODE_SHORTCUT representation of the slice.

setSubtitle

open fun setSubtitle(title: CharSequence): ListBuilder.RangeBuilder

Set the subtitle.