AccessibilityNodeInfoCompat.RangeInfoCompat

Added in 1.1.0

class AccessibilityNodeInfoCompat.RangeInfoCompat


Class with information if a node is a range.

Summary

Constants

const Int

Range type: float.

const Int

Range type: integer.

const Int

Range type: percent with values from zero to one.

Public constructors

RangeInfoCompat(type: Int, min: Float, max: Float, current: Float)

Creates a new range.

Public functions

Float

Gets the current value.

Float

Gets the max value.

Float

Gets the min value.

Int

Gets the range type.

java-static AccessibilityNodeInfoCompat.RangeInfoCompat!
obtain(type: Int, min: Float, max: Float, current: Float)

Obtains a cached instance if such is available otherwise a new one.

Constants

RANGE_TYPE_FLOAT

Added in 1.1.0
const val RANGE_TYPE_FLOAT = 1: Int

Range type: float.

RANGE_TYPE_INT

Added in 1.1.0
const val RANGE_TYPE_INT = 0: Int

Range type: integer.

RANGE_TYPE_PERCENT

Added in 1.1.0
const val RANGE_TYPE_PERCENT = 2: Int

Range type: percent with values from zero to one.

Public constructors

RangeInfoCompat

Added in 1.12.0
RangeInfoCompat(type: Int, min: Float, max: Float, current: Float)

Creates a new range.

Parameters
type: Int

The type of the range.

min: Float

The minimum value. Use Float.NEGATIVE_INFINITY if the range has no minimum.

max: Float

The maximum value. Use Float.POSITIVE_INFINITY if the range has no maximum.

current: Float

The current value.

Public functions

getCurrent

Added in 1.1.0
fun getCurrent(): Float

Gets the current value.

Returns
Float

The current value.

getMax

Added in 1.1.0
fun getMax(): Float

Gets the max value.

Returns
Float

The max value.

getMin

Added in 1.1.0
fun getMin(): Float

Gets the min value.

Returns
Float

The min value.

getType

Added in 1.1.0
fun getType(): Int

Gets the range type.

Returns
Int

The range type.

obtain

Added in 1.1.0
java-static fun obtain(type: Int, min: Float, max: Float, current: Float): AccessibilityNodeInfoCompat.RangeInfoCompat!

Obtains a cached instance if such is available otherwise a new one.

Parameters
type: Int

The type of the range.

min: Float

The min value.

max: Float

The max value.

current: Float

The current value.