# ConstraintSet

Artifact: [androidx.constraintlayout:constraintlayout](https://developer.android.com/jetpack/androidx/releases/constraintlayout) [View Source](https://cs.android.com/search?q=file:androidx/constraintlayout/widget/ConstraintSet.java+class:androidx.constraintlayout.widget.ConstraintSet) Added in [2.2.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#2.2.2)

*** ** * ** ***

<br />

```
class ConstraintSet
```

<br />

*** ** * ** ***

Defines a set of constraints to be used with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout`.

`ConstraintSet` enables you create and save constraints and apply them to an existing `ConstraintLayout`. For details about constraint behaviour, see `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout`.

`ConstraintsSet` can be created in various ways:

- Manually --- `c = new ConstraintSet(); c.connect(...);`
- From an `R.layout.*` object --- `c.clone(context, R.layout.layout1);`
- From a `ConstraintLayout` --- `c.clone(constraintLayout);`

Example code:

```kotlin
import android.content.Context;
     import android.os.Bundle;
     import android.support.constraint.ConstraintLayout;
     import android.support.constraint.ConstraintSet;
     import android.support.transition.TransitionManager;
     import android.support.v7.app.AppCompatActivity;
     import android.view.View;

     public class MainActivity extends AppCompatActivity {
         ConstraintSet mConstraintSet1 = new ConstraintSet(); // Create a ConstraintSet.
         ConstraintSet mConstraintSet2 = new ConstraintSet(); // Create a ConstraintSet.
         ConstraintLayout mConstraintLayout; // Cache the ConstraintLayout.
         boolean mOld = true;


         protected void onCreate(Bundle savedInstanceState) {
             super.onCreate(savedInstanceState);
             Context context = this;
             mConstraintSet2.clone(context, R.layout.state2); // Get constraints from layout.
             setContentView(R.layout.state1);
             mConstraintLayout = (ConstraintLayout) findViewById(R.id.activity_main);
             mConstraintSet1.clone(mConstraintLayout); // Get constraints from ConstraintSet.
         }

         public void foo(View view) {
             TransitionManager.beginDelayedTransition(mConstraintLayout);
             if (mOld = !mOld) {
                 mConstraintSet1.applyTo(mConstraintLayout); // Set new constraints.
             }  else {
                 mConstraintSet2.applyTo(mConstraintLayout); // Set new constraints.
             }
         }
     }
```

## Summary

| ### Nested types |
|---|
| `class https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint` |
| `class https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Layout` |
| `class https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Motion` |
| `class https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.PropertySet` |
| `class https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Transform` |

| ### Constants |
|---|---|
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BASELINE() = 5` The baseline of the text in a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM() = 4` The bottom side of a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_PACKED() = 2` Chain packed style |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD() = 0` Chain spread style |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD_INSIDE() = 1` Chain spread inside style |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CIRCLE_REFERENCE() = 8` Circle reference from a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END() = 7` The right side of a view in left to right languages. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#GONE() = 8` This view is gone, and will not take any space for layout purposes. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#HORIZONTAL() = 0` The horizontal orientation. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#HORIZONTAL_GUIDELINE() = 0` Used to create a horizontal create guidelines. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#INVISIBLE() = 4` This view is invisible, but it still takes up space for layout purposes. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT() = 1` The left side of a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT() = 0` Dimension will be controlled by constraints |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT_PERCENT() = 2` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT_SPREAD() = 0` Calculate the size of a view in 0 dp by reducing the constrains gaps as much as possible |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT_WRAP() = 1` How to calculate the size of a view in 0 dp by using its wrap_content size |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#PARENT_ID() = 0` References the id of the parent. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT() = 2` The right side of a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ROTATE_LEFT_OF_PORTRATE() = 4` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ROTATE_NONE() = 0` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ROTATE_PORTRATE_OF_LEFT() = 2` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ROTATE_PORTRATE_OF_RIGHT() = 1` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ROTATE_RIGHT_OF_PORTRATE() = 3` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START() = 6` The left side of a view in left to right languages. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP() = 3` The top of a view. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#UNSET() = -1` Used to indicate a parameter is cleared or not set |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VERTICAL() = 1` The vertical orientation. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VERTICAL_GUIDELINE() = 1` Used to create a vertical create guidelines. see `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#create(int,int)` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_IGNORE() = 1` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_NORMAL() = 0` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBLE() = 0` This view is visible. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#WRAP_CONTENT() = -2` Dimension will set by the view's content |

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#ConstraintSet()()` |

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addColorAttributes(java.lang.String...)(attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Add attribute of type Color |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addFloatAttributes(java.lang.String...)(attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Add attribute of type float |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addIntAttributes(java.lang.String...)(attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Add attribute of type Int |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addStringAttributes(java.lang.String...)(attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Add attribute of type string |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addToHorizontalChain(int,int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Adds a view to a horizontal chain. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addToHorizontalChainRTL(int,int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Adds a view to a horizontal chain. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#addToVerticalChain(int,int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Adds a view to a vertical chain. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyCustomAttributes(androidx.constraintlayout.widget.ConstraintLayout)(constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!)` Apply custom attributes alone |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyDeltaFrom(androidx.constraintlayout.widget.ConstraintSet)(cs: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!)` Get the delta form the ConstraintSet and aplly to this |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyTo(androidx.constraintlayout.widget.ConstraintLayout)(constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!)` Apply the constraints to a ConstraintLayout. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyToHelper(androidx.constraintlayout.widget.ConstraintHelper,androidx.constraintlayout.core.widgets.ConstraintWidget,androidx.constraintlayout.widget.ConstraintLayout.LayoutParams,android.util.SparseArray<androidx.constraintlayout.core.widgets.ConstraintWidget>)( helper: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintHelper!, child: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/widgets/ConstraintWidget!, layoutParams: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout.LayoutParams!, mapIdToWidget: https://developer.android.com/reference/android/util/SparseArray.html<https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/widgets/ConstraintWidget!>! )` Apply Layout to Helper widget |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyToLayoutParams(int,androidx.constraintlayout.widget.ConstraintLayout.LayoutParams)(id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, layoutParams: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout.LayoutParams!)` Fill in a ConstraintLayout LayoutParam based on the id. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#applyToWithoutCustom(androidx.constraintlayout.widget.ConstraintLayout)(constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!)` Apply the constraints to a ConstraintLayout. |
| `java-static https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#buildDelta(android.content.Context,org.xmlpull.v1.XmlPullParser)(context: https://developer.android.com/reference/android/content/Context.html!, parser: https://developer.android.com/reference/org/xmlpull/v1/XmlPullParser.html!)` Used to read a ConstraintDelta |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#center(int,int,int,int,int,int,int,float)( centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, firstID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, firstSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, firstMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, secondId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, secondSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, secondMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Center widget between the other two widgets. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerHorizontally(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Centers the view horizontally relative to toView's position. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerHorizontally(int,int,int,int,int,int,int,float)( centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Centers the widget horizontally to the left and right side on another widgets sides. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerHorizontallyRtl(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Centers the view horizontally relative to toView's position. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerHorizontallyRtl(int,int,int,int,int,int,int,float)( centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Centers the widgets horizontally to the left and right side on another widgets sides. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerVertically(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Centers the view vertically relative to toView's position. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#centerVertically(int,int,int,int,int,int,int,float)( centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, topSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, topMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Centers the widgets vertically to the top and bottom side on another widgets sides. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clear(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Remove all constraints from this view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clear(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Remove a constraint from this view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clone(androidx.constraintlayout.widget.ConstraintLayout)(constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!)` Copy the layout parameters of a ConstraintLayout. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clone(androidx.constraintlayout.widget.Constraints)(constraints: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/Constraints!)` Copy the layout parameters of a ConstraintLayout. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clone(androidx.constraintlayout.widget.ConstraintSet)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!)` Copy the constraints from a layout. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#clone(android.content.Context,int)(context: https://developer.android.com/reference/android/content/Context.html!, constraintLayoutId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Copy the constraints from a layout. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#connect(int,int,int,int)(startID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Create a constraint between two widgets. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#connect(int,int,int,int,int)(startID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Create a constraint between two widgets. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainCircle(int,int,int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, radius: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, angle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Constrain the view on a circle constraint |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainDefaultHeight(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets how the height is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainDefaultWidth(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets how the width is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainHeight(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the height of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainMaxHeight(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the maximum height of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainMaxWidth(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the maximum width of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainMinHeight(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the height of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainMinWidth(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the width of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainPercentHeight(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, percent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Sets the height of the view as a percentage of the parent. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainPercentWidth(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, percent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Sets the width of the view as a percentage of the parent. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainWidth(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the width of the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainedHeight(int,boolean)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, constrained: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` Sets how the height is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#constrainedWidth(int,boolean)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, constrained: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` Sets how the width is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#create(int,int)(guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, orientation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Creates a ConstraintLayout virtual object. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#createBarrier(int,int,int,int...)( id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, direction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, referenced: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>! )` Creates a ConstraintLayout Barrier object. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#createHorizontalChain(int,int,int,int,int[],float[],int)( leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, leftSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rightSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!, weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!, style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` Spaces a set of widgets horizontally between the view startID and endId. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#createHorizontalChainRtl(int,int,int,int,int[],float[],int)( startId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!, weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!, style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` Spaces a set of widgets horizontal between the view startID and endId. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#createVerticalChain(int,int,int,int,int[],float[],int)( topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, topSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bottomSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!, weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!, style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` Spaces a set of widgets vertically between the view topId and bottomId. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#dump(androidx.constraintlayout.motion.widget.MotionScene,int...)(scene: https://developer.android.com/reference/kotlin/androidx/constraintlayout/motion/widget/MotionScene!, ids: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!)` Dump the contents |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getApplyElevation(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` return with the constraint set will apply elevation for the specified view. |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getConstraint(int)(id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` |
| `https://developer.android.com/reference/java/util/HashMap.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintAttribute!>!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getCustomAttributeSet()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getHeight(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Get the height set in the view |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getKnownIds()()` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getParameters(int)(mId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getReferencedIds(int)(id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` get the reference id's of a helper. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getStateLabels()()` Get the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getVisibility(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Get the visibility flag set in this view |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getVisibilityMode(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` ConstraintSet will not setVisibility. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#getWidth(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Get the width set in the view |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#isForceId()()` Enforce id are required for all ConstraintLayout children to use ConstraintSet. default = true; |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#isValidateOnParse()()` If true perform validation checks when parsing ConstraintSets This will slow down parsing and should only be used for debugging |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#load(android.content.Context,org.xmlpull.v1.XmlPullParser)(context: https://developer.android.com/reference/android/content/Context.html!, parser: https://developer.android.com/reference/org/xmlpull/v1/XmlPullParser.html!)` Load a constraint set from a constraintSet.xml file |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#load(android.content.Context,int)(context: https://developer.android.com/reference/android/content/Context.html!, resourceId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Load a constraint set from a constraintSet.xml file. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#matchesLabels(java.lang.String...)(types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Test if the list of strings matches labels defined on this constraintSet |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#parseColorAttributes(androidx.constraintlayout.widget.ConstraintSet.Constraint,java.lang.String)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!, attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Parse color |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#parseFloatAttributes(androidx.constraintlayout.widget.ConstraintSet.Constraint,java.lang.String)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!, attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Parse floats |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#parseIntAttributes(androidx.constraintlayout.widget.ConstraintSet.Constraint,java.lang.String)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!, attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Parse int |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#parseStringAttributes(androidx.constraintlayout.widget.ConstraintSet.Constraint,java.lang.String)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!, attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Parse string |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#readFallback(androidx.constraintlayout.widget.ConstraintLayout)(constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!)` This will copy Constraints from the ConstraintLayout if it does not have parameters |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#readFallback(androidx.constraintlayout.widget.ConstraintSet)(set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!)` This will copy Constraints from the ConstraintSet |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#removeAttribute(java.lang.String)(attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Remove the attribute |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#removeFromHorizontalChain(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Removes a view from a horizontal chain. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#removeFromVerticalChain(int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Removes a view from a vertical chain. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setAlpha(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, alpha: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the alpha of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setApplyElevation(int,boolean)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, apply: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` set if elevation will be applied to the view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setBarrierType(int,int)(id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, type: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` SEt tye type of barier |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setColorValue(int,java.lang.String,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Set the value of an attribute of type color |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setDimensionRatio(int,java.lang.String)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Constrains the views aspect ratio. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setEditorAbsoluteX(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, position: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setEditorAbsoluteY(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, position: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setElevation(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, elevation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the elevation of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setFloatValue(int,java.lang.String,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Set the value of an attribute of type float |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setForceId(boolean)(forceId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` Enforce id are required for all ConstraintLayout children to use ConstraintSet. default = true; |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setGoneMargin(int,int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the gone margin. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setGuidelineBegin(int,int)(guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Set the guideline's distance form the top or left edge. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setGuidelineEnd(int,int)(guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Set a guideline's distance to end. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setGuidelinePercent(int,float)(guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Set a Guideline's percent. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setHorizontalBias(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the horizontal bias of the view (used with views constrained on left and right). |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setHorizontalChainStyle(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, chainStyle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` How the elements of the horizontal chain will be positioned. if the dimension behaviour is set to MATCH_CONSTRAINT. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setHorizontalWeight(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` The child's weight that we can use to distribute the available horizontal space in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setIntValue(int,java.lang.String,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Set the value of an attribute of type int |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setLayoutWrapBehavior(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, behavior: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the wrap behavior of the widget in the parent's wrap computation |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setMargin(int,int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the margin. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setReferencedIds(int,int...)(id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, referenced: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!)` sets the reference id's of a barrier. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setRotation(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rotation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout rotation about the Z axis of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setRotationX(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rotationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout rotation about the X axis of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setRotationY(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, rotationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout rotation about the Y axis of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setScaleX(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, scaleX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout scale in X of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setScaleY(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, scaleY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout scale in Y of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setStateLabels(java.lang.String)(types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Set the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setStateLabelsList(java.lang.String...)(types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!)` Set the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setStringValue(int,java.lang.String,java.lang.String)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Set the value of an attribute of type string |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTransformPivot(int,float,float)( viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, transformPivotX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, transformPivotY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Set X,Y location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTransformPivotX(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, transformPivotX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Set X location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTransformPivotY(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, transformPivotY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Set Y location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTranslation(int,float,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, translationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, translationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout translation of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTranslationX(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, translationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout X translation of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTranslationY(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, translationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the post-layout Y translation of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setTranslationZ(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, translationZ: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the translation in Z of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setValidateOnParse(boolean)(validate: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` If true perform validation checks when parsing ConstraintSets This will slow down parsing and should only be used for debugging |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVerticalBias(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Adjust the vertical bias of the view (used with views constrained on left and right). |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVerticalChainStyle(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, chainStyle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` How the elements of the vertical chain will be positioned. in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVerticalWeight(int,float)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` The child's weight that we can use to distribute the available vertical space in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVisibility(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, visibility: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Adjust the visibility of a view. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVisibilityMode(int,int)(viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, visibilityMode: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` ConstraintSet will not setVisibility. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#writeState(java.io.Writer,androidx.constraintlayout.widget.ConstraintLayout,int)(writer: https://developer.android.com/reference/java/io/Writer.html!, layout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!, flags: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Write the state to a Writer |

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#derivedState()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#mIdString()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#mRotate()` |

## Constants

### BASELINE

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

```
const val BASELINE = 5: Int
```

The baseline of the text in a view.

### BOTTOM

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

```
const val BOTTOM = 4: Int
```

The bottom side of a view.

### CHAIN_PACKED

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

```
const val CHAIN_PACKED = 2: Int
```

Chain packed style

### CHAIN_SPREAD

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

```
const val CHAIN_SPREAD = 0: Int
```

Chain spread style

### CHAIN_SPREAD_INSIDE

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

```
const val CHAIN_SPREAD_INSIDE = 1: Int
```

Chain spread inside style

### CIRCLE_REFERENCE

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

```
const val CIRCLE_REFERENCE = 8: Int
```

Circle reference from a view.

### END

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

```
const val END = 7: Int
```

The right side of a view in left to right languages. In right to left languages it corresponds to the left side of the view

### GONE

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

```
const val GONE = 8: Int
```

This view is gone, and will not take any space for layout purposes. Use with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVisibility(int,int)` and [` android:visibility`.](https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#attr_android:visibility)

### HORIZONTAL

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

```
const val HORIZONTAL = 0: Int
```

The horizontal orientation.

### HORIZONTAL_GUIDELINE

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

```
const val HORIZONTAL_GUIDELINE = 0: Int
```

Used to create a horizontal create guidelines.

### INVISIBLE

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

```
const val INVISIBLE = 4: Int
```

This view is invisible, but it still takes up space for layout purposes. Use with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVisibility(int,int)` and [` android:visibility`.](https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#attr_android:visibility)

### LEFT

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

```
const val LEFT = 1: Int
```

The left side of a view.

### MATCH_CONSTRAINT

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

```
const val MATCH_CONSTRAINT = 0: Int
```

Dimension will be controlled by constraints

### MATCH_CONSTRAINT_PERCENT

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

```
const val MATCH_CONSTRAINT_PERCENT = 2: Int
```

### MATCH_CONSTRAINT_SPREAD

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

```
const val MATCH_CONSTRAINT_SPREAD = 0: Int
```

Calculate the size of a view in 0 dp by reducing the constrains gaps as much as possible

### MATCH_CONSTRAINT_WRAP

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

```
const val MATCH_CONSTRAINT_WRAP = 1: Int
```

How to calculate the size of a view in 0 dp by using its wrap_content size

### PARENT_ID

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

```
const val PARENT_ID = 0: Int
```

References the id of the parent. Used in:

- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#connect(int,int,int,int,int)`
- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#center(int,int,int,int,int,int,int,float)`

### RIGHT

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

```
const val RIGHT = 2: Int
```

The right side of a view.

### ROTATE_LEFT_OF_PORTRATE

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

```
const val ROTATE_LEFT_OF_PORTRATE = 4: Int
```

### ROTATE_NONE

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

```
const val ROTATE_NONE = 0: Int
```

### ROTATE_PORTRATE_OF_LEFT

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

```
const val ROTATE_PORTRATE_OF_LEFT = 2: Int
```

### ROTATE_PORTRATE_OF_RIGHT

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

```
const val ROTATE_PORTRATE_OF_RIGHT = 1: Int
```

### ROTATE_RIGHT_OF_PORTRATE

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

```
const val ROTATE_RIGHT_OF_PORTRATE = 3: Int
```

### START

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

```
const val START = 6: Int
```

The left side of a view in left to right languages. In right to left languages it corresponds to the right side of the view

### TOP

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

```
const val TOP = 3: Int
```

The top of a view.

### UNSET

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

```
const val UNSET = -1: Int
```

Used to indicate a parameter is cleared or not set

### VERTICAL

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

```
const val VERTICAL = 1: Int
```

The vertical orientation.

### VERTICAL_GUIDELINE

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

```
const val VERTICAL_GUIDELINE = 1: Int
```

Used to create a vertical create guidelines. see `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#create(int,int)`

### VISIBILITY_MODE_IGNORE

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

```
const val VISIBILITY_MODE_IGNORE = 1: Int
```

### VISIBILITY_MODE_NORMAL

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

```
const val VISIBILITY_MODE_NORMAL = 0: Int
```

### VISIBLE

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

```
const val VISIBLE = 0: Int
```

This view is visible. Use with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#setVisibility(int,int)` and [` android:visibility`.](https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#attr_android:visibility)

### WRAP_CONTENT

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

```
const val WRAP_CONTENT = -2: Int
```

Dimension will set by the view's content

## Public constructors

### ConstraintSet

Added in 2.2.2

```
ConstraintSet()
```

## Public functions

### addColorAttributes

```
fun addColorAttributes(attributeName: Array<String!>!): Unit
```

Add attribute of type Color

| Parameters |
|---|---|
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` |   |

### addFloatAttributes

```
fun addFloatAttributes(attributeName: Array<String!>!): Unit
```

Add attribute of type float

| Parameters |
|---|---|
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` |   |

### addIntAttributes

```
fun addIntAttributes(attributeName: Array<String!>!): Unit
```

Add attribute of type Int

| Parameters |
|---|---|
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` |   |

### addStringAttributes

```
fun addStringAttributes(attributeName: Array<String!>!): Unit
```

Add attribute of type string

| Parameters |
|---|---|
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` |   |

### addToHorizontalChain

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

```
fun addToHorizontalChain(viewId: Int, leftId: Int, rightId: Int): Unit
```

Adds a view to a horizontal chain.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view to add |
| `leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view in chain to the left |
| `rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view in chain to the right |

### addToHorizontalChainRTL

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

```
fun addToHorizontalChainRTL(viewId: Int, leftId: Int, rightId: Int): Unit
```

Adds a view to a horizontal chain.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view to add |
| `leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view to the start side |
| `rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view to the end side |

### addToVerticalChain

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

```
fun addToVerticalChain(viewId: Int, topId: Int, bottomId: Int): Unit
```

Adds a view to a vertical chain.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view to add to a vertical chain |
| `topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view above. |
| `bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | view below |

### applyCustomAttributes

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

```
fun applyCustomAttributes(constraintLayout: ConstraintLayout!): Unit
```

Apply custom attributes alone

| Parameters |
|---|---|
| `constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` |   |

### applyDeltaFrom

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

```
fun applyDeltaFrom(cs: ConstraintSet!): Unit
```

Get the delta form the ConstraintSet and aplly to this

| Parameters |
|---|---|
| `cs: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!` |   |

### applyTo

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

```
fun applyTo(constraintLayout: ConstraintLayout!): Unit
```

Apply the constraints to a ConstraintLayout.

| Parameters |
|---|---|
| `constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` | to be modified |

### applyToHelper

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

```
fun applyToHelper(
    helper: ConstraintHelper!,
    child: ConstraintWidget!,
    layoutParams: ConstraintLayout.LayoutParams!,
    mapIdToWidget: SparseArray<ConstraintWidget!>!
): Unit
```

Apply Layout to Helper widget

| Parameters |
|---|---|
| `helper: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintHelper!` |   |
| `child: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/widgets/ConstraintWidget!` |   |
| `layoutParams: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout.LayoutParams!` |   |
| `mapIdToWidget: https://developer.android.com/reference/android/util/SparseArray.html<https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/widgets/ConstraintWidget!>!` |   |

### applyToLayoutParams

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

```
fun applyToLayoutParams(id: Int, layoutParams: ConstraintLayout.LayoutParams!): Unit
```

Fill in a ConstraintLayout LayoutParam based on the id.

| Parameters |
|---|---|
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | Id of the view |
| `layoutParams: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout.LayoutParams!` | LayoutParams to be filled |

### applyToWithoutCustom

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

```
fun applyToWithoutCustom(constraintLayout: ConstraintLayout!): Unit
```

Apply the constraints to a ConstraintLayout.

| Parameters |
|---|---|
| `constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` | to be modified |

### buildDelta

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

```
java-static fun buildDelta(context: Context!, parser: XmlPullParser!): ConstraintSet.Constraint!
```

Used to read a ConstraintDelta

| Parameters |
|---|---|
| `context: https://developer.android.com/reference/android/content/Context.html!` |   |
| `parser: https://developer.android.com/reference/org/xmlpull/v1/XmlPullParser.html!` |   |

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |

### center

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

```
fun center(
    centerID: Int,
    firstID: Int,
    firstSide: Int,
    firstMargin: Int,
    secondId: Int,
    secondSide: Int,
    secondMargin: Int,
    bias: Float
): Unit
```

Center widget between the other two widgets. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`) Note, sides must be all vertical or horizontal sides.

| Parameters |
|---|---|
| `centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the widget to be centered |
| `firstID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the first widget to connect the left or top of the widget to |
| `firstSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the widget to connect to |
| `firstMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the connection margin |
| `secondId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the ID of the second widget to connect to right or top of the widget to |
| `secondSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the widget to connect to |
| `secondMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the connection margin |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the ratio between two connections |

### centerHorizontally

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

```
fun centerHorizontally(viewId: Int, toView: Int): Unit
```

Centers the view horizontally relative to toView's position.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center Horizontally |
| `toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center on (or in) |

### centerHorizontally

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

```
fun centerHorizontally(
    centerID: Int,
    leftId: Int,
    leftSide: Int,
    leftMargin: Int,
    rightId: Int,
    rightSide: Int,
    rightMargin: Int,
    bias: Float
): Unit
```

Centers the widget horizontally to the left and right side on another widgets sides. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`)

| Parameters |
|---|---|
| `centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of widget to be centered |
| `leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the left side |
| `leftSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the leftId widget to connect to |
| `leftMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the left side |
| `rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the right side |
| `rightSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the rightId widget to connect to |
| `rightMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the right side |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | The ratio of the space on the left vs. right sides 0.5 is centered (default) |

### centerHorizontallyRtl

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

```
fun centerHorizontallyRtl(viewId: Int, toView: Int): Unit
```

Centers the view horizontally relative to toView's position.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center Horizontally |
| `toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center on (or in) |

### centerHorizontallyRtl

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

```
fun centerHorizontallyRtl(
    centerID: Int,
    startId: Int,
    startSide: Int,
    startMargin: Int,
    endId: Int,
    endSide: Int,
    endMargin: Int,
    bias: Float
): Unit
```

Centers the widgets horizontally to the left and right side on another widgets sides. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`)

| Parameters |
|---|---|
| `centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of widget to be centered |
| `startId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the start side (left in non rtl languages) |
| `startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the startId widget to connect to |
| `startMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the start side |
| `endId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the start side (left in non rtl languages) |
| `endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the endId widget to connect to |
| `endMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the end side |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | The ratio of the space on the start vs end side 0.5 is centered (default) |

### centerVertically

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

```
fun centerVertically(viewId: Int, toView: Int): Unit
```

Centers the view vertically relative to toView's position.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center Horizontally |
| `toView: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center on (or in) |

### centerVertically

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

```
fun centerVertically(
    centerID: Int,
    topId: Int,
    topSide: Int,
    topMargin: Int,
    bottomId: Int,
    bottomSide: Int,
    bottomMargin: Int,
    bias: Float
): Unit
```

Centers the widgets vertically to the top and bottom side on another widgets sides. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM()`)

| Parameters |
|---|---|
| `centerID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of widget to be centered |
| `topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the top side |
| `topSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the leftId widget to connect to |
| `topMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the top side |
| `bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The Id of the widget on the bottom side |
| `bottomSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side of the bottomId widget to connect to |
| `bottomMargin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The margin on the bottom side |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | The ratio of the space on the top vs. bottom sides 0.5 is centered (default) |

### clear

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

```
fun clear(viewId: Int): Unit
```

Remove all constraints from this view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to remove all connections to |

### clear

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

```
fun clear(viewId: Int, anchor: Int): Unit
```

Remove a constraint from this view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to center on (or in) |
| `anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the Anchor to remove constraint from |

### clone

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

```
fun clone(constraintLayout: ConstraintLayout!): Unit
```

Copy the layout parameters of a ConstraintLayout.

| Parameters |
|---|---|
| `constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` | The ConstraintLayout to be copied |

### clone

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

```
fun clone(constraints: Constraints!): Unit
```

Copy the layout parameters of a ConstraintLayout.

| Parameters |
|---|---|
| `constraints: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/Constraints!` | The ConstraintLayout to be copied |

### clone

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

```
fun clone(set: ConstraintSet!): Unit
```

Copy the constraints from a layout.

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!` | constraint set to copy |

### clone

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

```
fun clone(context: Context!, constraintLayoutId: Int): Unit
```

Copy the constraints from a layout.

| Parameters |
|---|---|
| `context: https://developer.android.com/reference/android/content/Context.html!` | the context for the layout inflation |
| `constraintLayoutId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the layout file |

### connect

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

```
fun connect(startID: Int, startSide: Int, endID: Int, endSide: Int): Unit
```

Create a constraint between two widgets. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BASELINE()`)

| Parameters |
|---|---|
| `startID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the ID of the widget to be constrained |
| `startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the widget to constrain |
| `endID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the widget to constrain to |
| `endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of widget to constrain to |

### connect

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

```
fun connect(startID: Int, startSide: Int, endID: Int, endSide: Int, margin: Int): Unit
```

Create a constraint between two widgets. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BASELINE()`)

| Parameters |
|---|---|
| `startID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the ID of the widget to be constrained |
| `startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the widget to constrain |
| `endID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the widget to constrain to |
| `endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of widget to constrain to |
| `margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the margin to constrain (margin must be positive) |

### constrainCircle

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

```
fun constrainCircle(viewId: Int, id: Int, radius: Int, angle: Float): Unit
```

Constrain the view on a circle constraint

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the view we constrain |
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the view we constrain relative to |
| `radius: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the radius of the circle in degrees |
| `angle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the angle |

### constrainDefaultHeight

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

```
fun constrainDefaultHeight(viewId: Int, height: Int): Unit
```

Sets how the height is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. Default is spread.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its matchConstraintDefaultHeight |
| `height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD |

### constrainDefaultWidth

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

```
fun constrainDefaultWidth(viewId: Int, width: Int): Unit
```

Sets how the width is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. Default is spread.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its matchConstraintDefaultWidth |
| `width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | SPREAD or WRAP |

### constrainHeight

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

```
fun constrainHeight(viewId: Int, height: Int): Unit
```

Sets the height of the view. It can be a dimension, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#WRAP_CONTENT()` or `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT()`.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its height |
| `height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the height of the view |

### constrainMaxHeight

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

```
fun constrainMaxHeight(viewId: Int, height: Int): Unit
```

Sets the maximum height of the view. It is a dimension, It is only applicable if height is #MATCH_CONSTRAINT}.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust it height |
| `height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the maximum height of the constraint |

### constrainMaxWidth

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

```
fun constrainMaxWidth(viewId: Int, width: Int): Unit
```

Sets the maximum width of the view. It is a dimension, It is only applicable if width is #MATCH_CONSTRAINT}.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its max height |
| `width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the maximum width of the view |

### constrainMinHeight

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

```
fun constrainMinHeight(viewId: Int, height: Int): Unit
```

Sets the height of the view. It is a dimension, It is only applicable if height is #MATCH_CONSTRAINT}.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its min height |
| `height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the minimum height of the view |

### constrainMinWidth

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

```
fun constrainMinWidth(viewId: Int, width: Int): Unit
```

Sets the width of the view. It is a dimension, It is only applicable if width is #MATCH_CONSTRAINT}.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its min height |
| `width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the minimum width of the view |

### constrainPercentHeight

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

```
fun constrainPercentHeight(viewId: Int, percent: Float): Unit
```

Sets the height of the view as a percentage of the parent.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `percent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` |   |

### constrainPercentWidth

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

```
fun constrainPercentWidth(viewId: Int, percent: Float): Unit
```

Sets the width of the view as a percentage of the parent.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `percent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` |   |

### constrainWidth

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

```
fun constrainWidth(viewId: Int, width: Int): Unit
```

Sets the width of the view. It can be a dimension, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#WRAP_CONTENT()` or `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#MATCH_CONSTRAINT()`.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its width |
| `width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the width of the view |

### constrainedHeight

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

```
fun constrainedHeight(viewId: Int, constrained: Boolean): Unit
```

Sets how the height is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. Default is spread.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its matchConstraintDefaultHeight |
| `constrained: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | if true height will be constrained |

### constrainedWidth

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

```
fun constrainedWidth(viewId: Int, constrained: Boolean): Unit
```

Sets how the width is calculated ether MATCH_CONSTRAINT_WRAP or MATCH_CONSTRAINT_SPREAD. Default is spread.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its matchConstraintDefaultWidth |
| `constrained: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | if true with will be constrained |

### create

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

```
fun create(guidelineID: Int, orientation: Int): Unit
```

Creates a ConstraintLayout virtual object. Currently only horizontal or vertical GuideLines.

| Parameters |
|---|---|
| `guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of guideline to create |
| `orientation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the Orientation of the guideline |

### createBarrier

```
fun createBarrier(
    id: Int,
    direction: Int,
    margin: Int,
    referenced: IntArray<Int>!
): Unit
```

Creates a ConstraintLayout Barrier object.

| Parameters |
|---|---|
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `direction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | Barrier.{LEFT,RIGHT,TOP,BOTTOM,START,END} |
| `referenced: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` |   |

### createHorizontalChain

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

```
fun createHorizontalChain(
    leftId: Int,
    leftSide: Int,
    rightId: Int,
    rightSide: Int,
    chainIds: IntArray<Int>!,
    weights: FloatArray<Float>!,
    style: Int
): Unit
```

Spaces a set of widgets horizontally between the view startID and endId. Widgets can be spaced with weights. This operation sets all the related margins to 0.

(for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`)

| Parameters |
|---|---|
| `leftId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `leftSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the start to connect to |
| `rightId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `rightSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the right to connect to |
| `chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | The widgets in the chain |
| `weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!` | The weight to assign to each element in the chain or null |
| `style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The type of chain |

### createHorizontalChainRtl

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

```
fun createHorizontalChainRtl(
    startId: Int,
    startSide: Int,
    endId: Int,
    endSide: Int,
    chainIds: IntArray<Int>!,
    weights: FloatArray<Float>!,
    style: Int
): Unit
```

Spaces a set of widgets horizontal between the view startID and endId. Widgets can be spaced with weights. (for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#START()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#END()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#LEFT()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#RIGHT()`)

| Parameters |
|---|---|
| `startId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `startSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the start to connect to |
| `endId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `endSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the end to connect to |
| `chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | The widgets in the chain |
| `weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!` | The weight to assign to each element in the chain or null |
| `style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The type of chain |

### createVerticalChain

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

```
fun createVerticalChain(
    topId: Int,
    topSide: Int,
    bottomId: Int,
    bottomSide: Int,
    chainIds: IntArray<Int>!,
    weights: FloatArray<Float>!,
    style: Int
): Unit
```

Spaces a set of widgets vertically between the view topId and bottomId. Widgets can be spaced with weights. This operation sets all the related margins to 0.

(for sides see: `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#TOP()`, `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#BOTTOM()`)

| Parameters |
|---|---|
| `topId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `topSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the start to connect to |
| `bottomId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The id of the widget to connect to or PARENT_ID |
| `bottomSide: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the side of the right to connect to |
| `chainIds: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | widgets to use as a chain |
| `weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html>!` | can be null |
| `style: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | set the style of the chain |

### dump

```
fun dump(scene: MotionScene!, ids: IntArray<Int>!): Unit
```

Dump the contents

| Parameters |
|---|---|
| `scene: https://developer.android.com/reference/kotlin/androidx/constraintlayout/motion/widget/MotionScene!` |   |
| `ids: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` |   |

### getApplyElevation

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

```
fun getApplyElevation(viewId: Int): Boolean
```

return with the constraint set will apply elevation for the specified view.

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | true if the elevation will be set on this view (default is false) |

### getConstraint

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

```
fun getConstraint(id: Int): ConstraintSet.Constraint!
```

### getCustomAttributeSet

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

```
fun getCustomAttributeSet(): HashMap<String!, ConstraintAttribute!>!
```

### getHeight

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

```
fun getHeight(viewId: Int): Int
```

Get the height set in the view

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the view |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | return the height constraint of the view |

### getKnownIds

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

```
fun getKnownIds(): Array<Int>!
```

### getParameters

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

```
fun getParameters(mId: Int): ConstraintSet.Constraint!
```

| Parameters |
|---|---|
| `mId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |

### getReferencedIds

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

```
fun getReferencedIds(id: Int): Array<Int>!
```

get the reference id's of a helper.

| Parameters |
|---|---|
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` | array of id's |

### getStateLabels

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

```
fun getStateLabels(): Array<String!>!
```

Get the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` | an array of type strings |

### getVisibility

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

```
fun getVisibility(viewId: Int): Int
```

Get the visibility flag set in this view

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the view |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the visibility constraint for the view |

### getVisibilityMode

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

```
fun getVisibilityMode(viewId: Int): Int
```

ConstraintSet will not setVisibility. `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_IGNORE()` or `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_NORMAL()`.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view |

### getWidth

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

```
fun getWidth(viewId: Int): Int
```

Get the width set in the view

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the id of the view |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | return the width constraint of the view |

### isForceId

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

```
fun isForceId(): Boolean
```

Enforce id are required for all ConstraintLayout children to use ConstraintSet. default = true;

### isValidateOnParse

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

```
fun isValidateOnParse(): Boolean
```

If true perform validation checks when parsing ConstraintSets This will slow down parsing and should only be used for debugging

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | validate |

### load

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

```
fun load(context: Context!, parser: XmlPullParser!): Unit
```

Load a constraint set from a constraintSet.xml file

| Parameters |
|---|---|
| `context: https://developer.android.com/reference/android/content/Context.html!` | the context for the inflation |
| `parser: https://developer.android.com/reference/org/xmlpull/v1/XmlPullParser.html!` | id of xml file in res/xml/ |

### load

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

```
fun load(context: Context!, resourceId: Int): Unit
```

Load a constraint set from a constraintSet.xml file. Note. Do NOT use this to load a layout file. It will fail silently as there is no efficient way to differentiate.

| Parameters |
|---|---|
| `context: https://developer.android.com/reference/android/content/Context.html!` | the context for the inflation |
| `resourceId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | id of xml file in res/xml/ |

### matchesLabels

```
fun matchesLabels(types: Array<String!>!): Boolean
```

Test if the list of strings matches labels defined on this constraintSet

| Parameters |
|---|---|
| `types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` | list of types |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | true if all types are in the labels |

### parseColorAttributes

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

```
fun parseColorAttributes(set: ConstraintSet.Constraint!, attributes: String!): Unit
```

Parse color

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |
| `attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### parseFloatAttributes

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

```
fun parseFloatAttributes(set: ConstraintSet.Constraint!, attributes: String!): Unit
```

Parse floats

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |
| `attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### parseIntAttributes

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

```
fun parseIntAttributes(set: ConstraintSet.Constraint!, attributes: String!): Unit
```

Parse int

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |
| `attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### parseStringAttributes

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

```
fun parseStringAttributes(set: ConstraintSet.Constraint!, attributes: String!): Unit
```

Parse string

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet.Constraint!` |   |
| `attributes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### readFallback

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

```
fun readFallback(constraintLayout: ConstraintLayout!): Unit
```

This will copy Constraints from the ConstraintLayout if it does not have parameters

| Parameters |
|---|---|
| `constraintLayout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` |   |

### readFallback

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

```
fun readFallback(set: ConstraintSet!): Unit
```

This will copy Constraints from the ConstraintSet

| Parameters |
|---|---|
| `set: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet!` |   |

### removeAttribute

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

```
fun removeAttribute(attributeName: String!): Unit
```

Remove the attribute

| Parameters |
|---|---|
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### removeFromHorizontalChain

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

```
fun removeFromHorizontalChain(viewId: Int): Unit
```

Removes a view from a horizontal chain. This assumes the view is connected to a horizontal chain. Its behaviour is undefined if not part of a horizontal chain.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the view to be removed |

### removeFromVerticalChain

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

```
fun removeFromVerticalChain(viewId: Int): Unit
```

Removes a view from a vertical chain. This assumes the view is connected to a vertical chain. Its behaviour is undefined if not part of a vertical chain.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the view to be removed |

### setAlpha

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

```
fun setAlpha(viewId: Int, alpha: Float): Unit
```

Adjust the alpha of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the vertical |
| `alpha: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the alpha |

### setApplyElevation

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

```
fun setApplyElevation(viewId: Int, apply: Boolean): Unit
```

set if elevation will be applied to the view. Elevation logic is based on style and animation. By default it is not used because it would lead to unexpected results.

| Parameters |
|---|---|
| `apply: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | true if this constraint set applies elevation to this view |

### setBarrierType

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

```
fun setBarrierType(id: Int, type: Int): Unit
```

SEt tye type of barier

| Parameters |
|---|---|
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `type: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

### setColorValue

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

```
fun setColorValue(viewId: Int, attributeName: String!, value: Int): Unit
```

Set the value of an attribute of type color

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

### setDimensionRatio

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

```
fun setDimensionRatio(viewId: Int, ratio: String!): Unit
```

Constrains the views aspect ratio. For Example a HD screen is 16 by 9 = 16/(float)9 = 1.777f.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to constrain |
| `ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The ratio of the width to height (width / height) |

### setEditorAbsoluteX

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

```
fun setEditorAbsoluteX(viewId: Int, position: Int): Unit
```

### setEditorAbsoluteY

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

```
fun setEditorAbsoluteY(viewId: Int, position: Int): Unit
```

### setElevation

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

```
fun setElevation(viewId: Int, elevation: Float): Unit
```

Adjust the elevation of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the elevation |
| `elevation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the elevation |

### setFloatValue

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

```
fun setFloatValue(viewId: Int, attributeName: String!, value: Float): Unit
```

Set the value of an attribute of type float

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` |   |

### setForceId

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

```
fun setForceId(forceId: Boolean): Unit
```

Enforce id are required for all ConstraintLayout children to use ConstraintSet. default = true;

| Parameters |
|---|---|
| `forceId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` |   |

### setGoneMargin

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

```
fun setGoneMargin(viewId: Int, anchor: Int, value: Int): Unit
```

Sets the gone margin.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the margin on |
| `anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side to adjust the margin on |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The new value for the margin |

### setGuidelineBegin

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

```
fun setGuidelineBegin(guidelineID: Int, margin: Int): Unit
```

Set the guideline's distance form the top or left edge.

| Parameters |
|---|---|
| `guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the guideline |
| `margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the distance to the top or left edge |

### setGuidelineEnd

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

```
fun setGuidelineEnd(guidelineID: Int, margin: Int): Unit
```

Set a guideline's distance to end.

| Parameters |
|---|---|
| `guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the guideline |
| `margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the margin to the right or bottom side of container |

### setGuidelinePercent

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

```
fun setGuidelinePercent(guidelineID: Int, ratio: Float): Unit
```

Set a Guideline's percent.

| Parameters |
|---|---|
| `guidelineID: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of the guideline |
| `ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the ratio between the gap on the left and right 0.0 is top/left 0.5 is middle |

### setHorizontalBias

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

```
fun setHorizontalBias(viewId: Int, bias: Float): Unit
```

Adjust the horizontal bias of the view (used with views constrained on left and right).

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the horizontal |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the new bias 0.5 is in the middle |

### setHorizontalChainStyle

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

```
fun setHorizontalChainStyle(viewId: Int, chainStyle: Int): Unit
```

How the elements of the horizontal chain will be positioned. if the dimension behaviour is set to MATCH_CONSTRAINT. The possible values are:

- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD()` -- the elements will be spread out
- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD_INSIDE()` -- similar, but the endpoints of the chain will not be spread out
- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_PACKED()` -- the elements of the chain will be packed together. The horizontal bias attribute of the child will then affect the positioning of the packed elements

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its HorizontalChainStyle |
| `chainStyle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the weight that we can use to distribute the horizontal space |

### setHorizontalWeight

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

```
fun setHorizontalWeight(viewId: Int, weight: Float): Unit
```

The child's weight that we can use to distribute the available horizontal space in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its HorizontalWeight |
| `weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the weight that we can use to distribute the horizontal space |

### setIntValue

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

```
fun setIntValue(viewId: Int, attributeName: String!, value: Int): Unit
```

Set the value of an attribute of type int

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

### setLayoutWrapBehavior

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

```
fun setLayoutWrapBehavior(viewId: Int, behavior: Int): Unit
```

Sets the wrap behavior of the widget in the parent's wrap computation

### setMargin

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

```
fun setMargin(viewId: Int, anchor: Int, value: Int): Unit
```

Sets the margin.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the margin on |
| `anchor: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The side to adjust the margin on |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | The new value for the margin |

### setReferencedIds

```
fun setReferencedIds(id: Int, referenced: IntArray<Int>!): Unit
```

sets the reference id's of a barrier.

| Parameters |
|---|---|
| `id: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `referenced: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html>!` |   |

### setRotation

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

```
fun setRotation(viewId: Int, rotation: Float): Unit
```

Adjust the post-layout rotation about the Z axis of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust th Z rotation |
| `rotation: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the rotation about the X axis |

### setRotationX

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

```
fun setRotationX(viewId: Int, rotationX: Float): Unit
```

Adjust the post-layout rotation about the X axis of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust th X rotation |
| `rotationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the rotation about the X axis |

### setRotationY

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

```
fun setRotationY(viewId: Int, rotationY: Float): Unit
```

Adjust the post-layout rotation about the Y axis of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the Y rotation |
| `rotationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the rotationY |

### setScaleX

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

```
fun setScaleX(viewId: Int, scaleX: Float): Unit
```

Adjust the post-layout scale in X of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the scale in X |
| `scaleX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the scale in X |

### setScaleY

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

```
fun setScaleY(viewId: Int, scaleY: Float): Unit
```

Adjust the post-layout scale in Y of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the scale in Y |
| `scaleY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the scale in Y |

### setStateLabels

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

```
fun setStateLabels(types: String!): Unit
```

Set the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet

| Parameters |
|---|---|
| `types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | a comer separated array of strings. |

### setStateLabelsList

```
fun setStateLabelsList(types: Array<String!>!): Unit
```

Set the types associated with this ConstraintSet The types mechanism allows you to tag the constraint set with a series of string to define properties of a ConstraintSet

| Parameters |
|---|---|
| `types: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>!` | a comer separated array of strings. |

### setStringValue

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

```
fun setStringValue(viewId: Int, attributeName: String!, value: String!): Unit
```

Set the value of an attribute of type string

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |
| `attributeName: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` |   |

### setTransformPivot

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

```
fun setTransformPivot(
    viewId: Int,
    transformPivotX: Float,
    transformPivotY: Float
): Unit
```

Set X,Y location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. Note: once an actual View has had its pivot set it cannot be cleared.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the transforms pivot point |
| `transformPivotX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | X location of the pivot point. |
| `transformPivotY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | Y location of the pivot point. |

### setTransformPivotX

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

```
fun setTransformPivotX(viewId: Int, transformPivotX: Float): Unit
```

Set X location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. Note: once an actual View has had its pivot set it cannot be cleared.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the transforms pivot point about X |
| `transformPivotX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | X location of the pivot point. |

### setTransformPivotY

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

```
fun setTransformPivotY(viewId: Int, transformPivotY: Float): Unit
```

Set Y location of the pivot point around which the view will rotate and scale. use Float.NaN to clear the pivot value. Note: once an actual View has had its pivot set it cannot be cleared.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the transforms pivot point about Y |
| `transformPivotY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | Y location of the pivot point. |

### setTranslation

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

```
fun setTranslation(viewId: Int, translationX: Float, translationY: Float): Unit
```

Adjust the post-layout translation of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its translation in X \&Y |
| `translationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the translation in X |
| `translationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the translation in Y |

### setTranslationX

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

```
fun setTranslationX(viewId: Int, translationX: Float): Unit
```

Adjust the post-layout X translation of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to translate in X |
| `translationX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the translation in X |

### setTranslationY

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

```
fun setTranslationY(viewId: Int, translationY: Float): Unit
```

Adjust the post-layout Y translation of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to to translate in Y |
| `translationY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the translation in Y |

### setTranslationZ

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

```
fun setTranslationZ(viewId: Int, translationZ: Float): Unit
```

Adjust the translation in Z of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust |
| `translationZ: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the translationZ |

### setValidateOnParse

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

```
fun setValidateOnParse(validate: Boolean): Unit
```

If true perform validation checks when parsing ConstraintSets This will slow down parsing and should only be used for debugging

| Parameters |
|---|---|
| `validate: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` |   |

### setVerticalBias

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

```
fun setVerticalBias(viewId: Int, bias: Float): Unit
```

Adjust the vertical bias of the view (used with views constrained on left and right).

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the vertical |
| `bias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the new bias 0.5 is in the middle |

### setVerticalChainStyle

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

```
fun setVerticalChainStyle(viewId: Int, chainStyle: Int): Unit
```

How the elements of the vertical chain will be positioned. in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT

- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD()` -- the elements will be spread out
- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_SPREAD_INSIDE()` -- similar, but the endpoints of the chain will not be spread out
- `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#CHAIN_PACKED()` -- the elements of the chain will be packed together. The vertical bias attribute of the child will then affect the positioning of the packed elements

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its VerticalChainStyle |
| `chainStyle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the weight that we can use to distribute the horizontal space |

### setVerticalWeight

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

```
fun setVerticalWeight(viewId: Int, weight: Float): Unit
```

The child's weight that we can use to distribute the available vertical space in a chain, if the dimension behaviour is set to MATCH_CONSTRAINT

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust its VerticalWeight |
| `weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | the weight that we can use to distribute the vertical space |

### setVisibility

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

```
fun setVisibility(viewId: Int, visibility: Int): Unit
```

Adjust the visibility of a view.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view to adjust the vertical |
| `visibility: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | the visibility |

### setVisibilityMode

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

```
fun setVisibilityMode(viewId: Int, visibilityMode: Int): Unit
```

ConstraintSet will not setVisibility. `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_IGNORE()` or `https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintSet#VISIBILITY_MODE_NORMAL()`.

| Parameters |
|---|---|
| `viewId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | ID of view |
| `visibilityMode: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

### writeState

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

```
fun writeState(writer: Writer!, layout: ConstraintLayout!, flags: Int): Unit
```

Write the state to a Writer

| Parameters |
|---|---|
| `writer: https://developer.android.com/reference/java/io/Writer.html!` |   |
| `layout: https://developer.android.com/reference/kotlin/androidx/constraintlayout/widget/ConstraintLayout!` |   |
| `flags: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` |   |

| Throws |
|---|---|
| `https://developer.android.com/reference/java/io/IOException.html` |   |

## Public properties

### derivedState

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

```
val derivedState: String!
```

### mIdString

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

```
val mIdString: String!
```

### mRotate

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

```
val mRotate: Int
```