# AccessibilityNodeInfo.RangeInfo

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)

# RangeInfo

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/view/accessibility/AccessibilityNodeInfo.RangeInfo "View this page in Java")  

```
class RangeInfo
```

|---|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)                                                                                           ||
| ↳ | [android.view.accessibility.AccessibilityNodeInfo.RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#) |

Class with information if a node is a range.

## Summary

|                                                                                                                                                 Constants                                                                                                                                                 ||
|----------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [RANGE_TYPE_FLOAT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT:kotlin.Int) Range type: float.                                            |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [RANGE_TYPE_INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE:kotlin.Int) Range type: indeterminate.                    |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [RANGE_TYPE_INT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT:kotlin.Int) Range type: integer.                                              |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [RANGE_TYPE_PERCENT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT:kotlin.Int) Range type: percent with values from zero to one hundred. |

|                                                                                                                                                                                                                                                                                     Public constructors                                                                                                                                                                                                                                                                                     ||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|
| [RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RangeInfo(kotlin.Int,%20kotlin.Float,%20kotlin.Float,%20kotlin.Float))`(`type:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`, `min:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`, `max:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`, `current:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Creates a new range. |

|                                                                                                                                                                                                                                                                                                                                                                  Public methods                                                                                                                                                                                                                                                                                                                                                                   ||
|------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)                                                                       | [getCurrent](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#getCurrent())`()` Gets the current value.                                                                                                                                                                                                                                                                                                                                                                                                                            |
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)                                                                       | [getMax](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#getMax())`()` Gets the maximum value.                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)                                                                       | [getMin](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#getMin())`()` Gets the minimum value.                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)                                                                           | [getType](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#getType())`()` Gets the range type.                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| static[AccessibilityNodeInfo.RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#)! | [obtain](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#obtain(kotlin.Int,%20kotlin.Float,%20kotlin.Float,%20kotlin.Float))`(`type:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`, `min:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`, `max:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`, `current:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Instantiates a new RangeInfo. |

|                                                                                                                                                                                                                                                                                                                               Properties                                                                                                                                                                                                                                                                                                                                ||
|-----------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| static[AccessibilityNodeInfo.RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#) | [INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#INDETERMINATE:android.view.accessibility.AccessibilityNodeInfo.RangeInfo) A[RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#)type used to represent a node which may typically expose range information but is presently in an indeterminate state, such as a representing a loading operation of unknown duration. |

## Constants

### RANGE_TYPE_FLOAT

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RANGE_TYPE_FLOAT: Int
```

Range type: float.  

    Value: 1

### RANGE_TYPE_INDETERMINATE

Added in[API level 36](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RANGE_TYPE_INDETERMINATE: Int
```

Range type: indeterminate. When using this type, the`min`,`max`, and`current`values used to construct an instance may be ignored.  

    Value: 3

**See Also**

- [#INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#INDETERMINATE:android.view.accessibility.AccessibilityNodeInfo.RangeInfo)  

### RANGE_TYPE_INT

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RANGE_TYPE_INT: Int
```

Range type: integer.  

    Value: 0

### RANGE_TYPE_PERCENT

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RANGE_TYPE_PERCENT: Int
```

Range type: percent with values from zero to one hundred.  

    Value: 2

## Public constructors

### RangeInfo

Added in[API level 30](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
RangeInfo(
    type: Int, 
    min: Float, 
    max: Float, 
    current: Float)
```

Creates a new range.

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         Parameters                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          ||
|-----------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `type`    | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):The type of the range. Value is[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT:kotlin.Int), or[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE:kotlin.Int) |
| `min`     | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The minimum value. Use`Float.NEGATIVE_INFINITY`if the range has no minimum.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `max`     | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The maximum value. Use`Float.POSITIVE_INFINITY`if the range has no maximum.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `current` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The current value.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |

## Public methods

### getCurrent

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun getCurrent(): Float
```

Gets the current value.

|                                               Return                                               ||
|--------------------------------------------------------------------------------|--------------------|
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html) | The current value. |

### getMax

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun getMax(): Float
```

Gets the maximum value.

|                                                                       Return                                                                        ||
|--------------------------------------------------------------------------------|---------------------------------------------------------------------|
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html) | The maximum value, or`Float.POSITIVE_INFINITY`if no maximum exists. |

### getMin

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun getMin(): Float
```

Gets the minimum value.

|                                                                       Return                                                                        ||
|--------------------------------------------------------------------------------|---------------------------------------------------------------------|
| [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html) | The minimum value, or`Float.NEGATIVE_INFINITY`if no minimum exists. |

### getType

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun getType(): Int
```

Gets the range type.

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   Return                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   ||
|----------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | The range type. Value is[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT:kotlin.Int), or[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE:kotlin.Int) |

**See Also**

- [#RANGE_TYPE_INT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT:kotlin.Int)
- [#RANGE_TYPE_FLOAT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT:kotlin.Int)
- [#RANGE_TYPE_PERCENT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT:kotlin.Int)  

### obtain

Added in[API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  
Deprecated in[API level 33](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static fun obtain(
    type: Int, 
    min: Float, 
    max: Float, 
    current: Float
): AccessibilityNodeInfo.RangeInfo!
```

**Deprecated:** *Object pooling has been discontinued. Create a new instance using the constructor[AccessibilityNodeInfo.RangeInfo.RangeInfo(int, float, float,](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RangeInfo(kotlin.Int,%20kotlin.Float,%20kotlin.Float,%20kotlin.Float))instead.*

Instantiates a new RangeInfo.

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         Parameters                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          ||
|-----------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `type`    | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):The type of the range. Value is[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_FLOAT:kotlin.Int),[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_PERCENT:kotlin.Int), or[android.view.accessibility.AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#RANGE_TYPE_INDETERMINATE:kotlin.Int) |
| `min`     | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The minimum value. Use`Float.NEGATIVE_INFINITY`if the range has no minimum.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `max`     | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The maximum value. Use`Float.POSITIVE_INFINITY`if the range has no maximum.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `current` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The current value.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |

## Properties

### INDETERMINATE

Added in[API level 36](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val INDETERMINATE: AccessibilityNodeInfo.RangeInfo
```

A[RangeInfo](https://developer.android.com/reference/kotlin/android/view/accessibility/AccessibilityNodeInfo.RangeInfo#)type used to represent a node which may typically expose range information but is presently in an indeterminate state, such as a representing a loading operation of unknown duration.