# CoreMotionScene

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/state/CoreMotionScene.java+class:androidx.constraintlayout.core.state.CoreMotionScene) Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

*** ** * ** ***


```
public interface CoreMotionScene
```

<br />

*** ** * ** ***

This defines the interface to motionScene functionality

## Summary

| ### Public methods |
|---|---|
| `abstract https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#getConstraintSet(java.lang.String)(https://developer.android.com/reference/java/lang/String.html ext)` Get the ConstraintSet as a string |
| `abstract https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#getConstraintSet(int)(int index)` get a constraintset |
| `abstract https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#getTransition(java.lang.String)(https://developer.android.com/reference/java/lang/String.html str)` get a transition give the name |
| `abstract void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#setConstraintSetContent(java.lang.String,java.lang.String)(https://developer.android.com/reference/java/lang/String.html csName, https://developer.android.com/reference/java/lang/String.html toJSON)` set the constraintSet json string |
| `abstract void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#setDebugName(java.lang.String)(https://developer.android.com/reference/java/lang/String.html name)` set the debug name for remote access |
| `abstract void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/CoreMotionScene#setTransitionContent(java.lang.String,java.lang.String)(https://developer.android.com/reference/java/lang/String.html elementName, https://developer.android.com/reference/java/lang/String.html toJSON)` set the Transitions string onto the MotionScene |

## Public methods

### getConstraintSet

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

```
abstract String getConstraintSet(String ext)
```

Get the ConstraintSet as a string

### getConstraintSet

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

```
abstract String getConstraintSet(int index)
```

get a constraintset

| Parameters |
|---|---|
| `int index` | of the constraintset |

### getTransition

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

```
abstract String getTransition(String str)
```

get a transition give the name

| Parameters |
|---|---|
| `https://developer.android.com/reference/java/lang/String.html str` | the name of the transition |

| Returns |
|---|---|
| `https://developer.android.com/reference/java/lang/String.html` | the json of the transition |

### setConstraintSetContent

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

```
abstract void setConstraintSetContent(String csName, String toJSON)
```

set the constraintSet json string

| Parameters |
|---|---|
| `https://developer.android.com/reference/java/lang/String.html csName` | the name of the constraint set |
| `https://developer.android.com/reference/java/lang/String.html toJSON` | the json string of the constraintset |

### setDebugName

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

```
abstract void setDebugName(String name)
```

set the debug name for remote access

| Parameters |
|---|---|
| `https://developer.android.com/reference/java/lang/String.html name` | name to call this motion scene |

### setTransitionContent

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

```
abstract void setTransitionContent(String elementName, String toJSON)
```

set the Transitions string onto the MotionScene

| Parameters |
|---|---|
| `https://developer.android.com/reference/java/lang/String.html elementName` | the name of the element |