# SpringStopEngine

Artifact: [androidx.constraintlayout:constraintlayout-core](https://developer.android.com/jetpack/androidx/releases/constraintlayout) [View Source](https://cs.android.com/search?q=file:androidx/constraintlayout/core/motion/utils/SpringStopEngine.java+class:androidx.constraintlayout.core.motion.utils.SpringStopEngine) Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

*** ** * ** ***


```
class SpringStopEngine : StopEngine
```

<br />

*** ** * ** ***

This contains the class to provide the logic for an animation to come to a stop using a spring model.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#SpringStopEngine()()` |

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#debug(java.lang.String,float)(desc: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, time: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#getAcceleration()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#getInterpolation(float)(time: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#getVelocity()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#getVelocity(float)(time: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#isStopped()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/motion/utils/SpringStopEngine#springConfig(float,float,float,float,float,float,float,int)( currentPos: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, target: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, currentVelocity: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, mass: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, stiffness: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, damping: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, stopThreshold: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, boundaryMode: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |

## Public constructors

### SpringStopEngine

Added in 1.1.2

```
SpringStopEngine()
```

## Public functions

### debug

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun debug(desc: String!, time: Float): String!
```

### getAcceleration

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun getAcceleration(): Float
```

### getInterpolation

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun getInterpolation(time: Float): Float
```

### getVelocity

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun getVelocity(): Float
```

### getVelocity

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun getVelocity(time: Float): Float
```

### isStopped

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun isStopped(): Boolean
```

### springConfig

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun springConfig(
    currentPos: Float,
    target: Float,
    currentVelocity: Float,
    mass: Float,
    stiffness: Float,
    damping: Float,
    stopThreshold: Float,
    boundaryMode: Int
): Unit
```