# BarrierReference

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

*** ** * ** ***


```
public class BarrierReference extends HelperReference
```

<br />

|---|---|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object.html) ||||
| ↳ | [androidx.constraintlayout.core.state.ConstraintReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference) |||
|   | ↳ | [androidx.constraintlayout.core.state.HelperReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference) ||
|   |   | ↳ | [androidx.constraintlayout.core.state.helpers.BarrierReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference) |

*** ** * ** ***

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#BarrierReference(androidx.constraintlayout.core.state.State)(https://developer.android.com/reference/androidx/constraintlayout/core/state/State state)` |

| ### Public methods |
|---|---|
| `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#apply()()` |
| `https://developer.android.com/reference/androidx/constraintlayout/core/widgets/HelperWidget` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#getHelperWidget()()` |
| `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#margin(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html marginValue)` |
| `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#margin(int)(int value)` |
| `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/BarrierReference#setBarrierDirection(androidx.constraintlayout.core.state.State.Direction)(https://developer.android.com/reference/androidx/constraintlayout/core/state/State.Direction barrierDirection)` |

| ### Inherited fields |
|---|
| From [androidx.constraintlayout.core.state.ConstraintReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference) |---|---| | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mBottomToBottom()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mBottomToTop()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mEndToEnd()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mEndToStart()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mHorizontalBias()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mLeftToLeft()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mLeftToRight()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginBottom()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginBottomGone()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginEnd()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginEndGone()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginLeft()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginLeftGone()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginRight()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginRightGone()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginStart()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginStartGone()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginTop()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mMarginTopGone()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mRightToLeft()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mRightToRight()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mStartToEnd()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mStartToStart()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mTopToBottom()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mTopToTop()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#mVerticalBias()` | |
| From [androidx.constraintlayout.core.state.HelperReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference) |---|---| | `final https://developer.android.com/reference/androidx/constraintlayout/core/state/State` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#mHelperState()` | | `https://developer.android.com/reference/java/util/ArrayList.html<https://developer.android.com/reference/java/lang/Object.html>` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#mReferences()` | |

| ### Inherited methods |
|---|
| From [androidx.constraintlayout.core.state.ConstraintReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference) |---|---| | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#addCustomColor(java.lang.String,int)(https://developer.android.com/reference/java/lang/String.html name, int color)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#addCustomFloat(java.lang.String,float)(https://developer.android.com/reference/java/lang/String.html name, float value)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#alpha(float)(float alpha)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#applyWidgetConstraints()()` apply all the constraints attributes of the mConstraintWidget | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#baseline()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#baselineToBaseline(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#baselineToBottom(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#baselineToTop(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#bias(float)(float value)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#bottom()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#bottomToBottom(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#bottomToTop(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#centerHorizontally(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#centerVertically(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#circularConstraint(java.lang.Object,float,float)(https://developer.android.com/reference/java/lang/Object.html reference, float angle, float distance)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#clear()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#clearAll()()` Clears all constraints. | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#clearHorizontal()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#clearVertical()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/widgets/ConstraintWidget` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#createConstraintWidget()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#end()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#endToEnd(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#endToStart(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getAlpha()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/Facade` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getFacade()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getHeight()()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getHorizontalChainStyle()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getHorizontalChainWeight()()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getKey()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getPivotX()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getPivotY()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getRotationX()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getRotationY()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getRotationZ()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getScaleX()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getScaleY()()` | | `https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getTag()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getTranslationX()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getTranslationY()()` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getTranslationZ()()` | | `int` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getVerticalChainStyle(int)(int chainStyle)` | | `float` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getVerticalChainWeight()()` | | `https://developer.android.com/reference/java/lang/Object.html` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getView()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#getWidth()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#height(androidx.constraintlayout.core.state.Dimension)(https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension dimension)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#horizontalBias(float)(float value)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#left()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#leftToLeft(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#leftToRight(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#marginGone(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html marginGoneValue)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#marginGone(int)(int value)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#pivotX(float)(float x)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#pivotY(float)(float y)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#right()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#rightToLeft(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#rightToRight(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#rotationX(float)(float x)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#rotationY(float)(float y)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#rotationZ(float)(float z)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#scaleX(float)(float x)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#scaleY(float)(float y)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setConstraintWidget(androidx.constraintlayout.core.widgets.ConstraintWidget)(https://developer.android.com/reference/androidx/constraintlayout/core/widgets/ConstraintWidget widget)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setFacade(androidx.constraintlayout.core.state.helpers.Facade)(https://developer.android.com/reference/androidx/constraintlayout/core/state/helpers/Facade facade)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setHeight(androidx.constraintlayout.core.state.Dimension)(https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension dimension)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setHorizontalChainStyle(int)(int chainStyle)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setHorizontalChainWeight(float)(float weight)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setKey(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html key)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setTag(java.lang.String)(https://developer.android.com/reference/java/lang/String.html tag)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setVerticalChainStyle(int)(int chainStyle)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setVerticalChainWeight(float)(float weight)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setView(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html view)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#setWidth(androidx.constraintlayout.core.state.Dimension)(https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension dimension)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#start()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#startToEnd(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#startToStart(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#top()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#topToBottom(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#topToTop(java.lang.Object)(https://developer.android.com/reference/java/lang/Object.html reference)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#translationX(float)(float x)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#translationY(float)(float y)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#translationZ(float)(float z)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#validate()()` Validate the constraints | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#verticalBias(float)(float value)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#visibility(int)(int visibility)` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/ConstraintReference#width(androidx.constraintlayout.core.state.Dimension)(https://developer.android.com/reference/androidx/constraintlayout/core/state/Dimension dimension)` | |
| From [androidx.constraintlayout.core.state.HelperReference](https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference) |---|---| | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#add(java.lang.Object...)(Object[] objects)` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#applyBase()()` Allows the derived classes to invoke the apply method in the ConstraintReference | | `https://developer.android.com/reference/androidx/constraintlayout/core/widgets/ConstraintWidget` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#getConstraintWidget()()` | | `https://developer.android.com/reference/androidx/constraintlayout/core/state/State.Helper` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#getType()()` | | `void` | `https://developer.android.com/reference/androidx/constraintlayout/core/state/HelperReference#setHelperWidget(androidx.constraintlayout.core.widgets.HelperWidget)(https://developer.android.com/reference/androidx/constraintlayout/core/widgets/HelperWidget helperWidget)` | |

## Public constructors

### BarrierReference

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

```
public BarrierReference(State state)
```

## Public methods

### apply

```
public void apply()
```

### getHelperWidget

```
public HelperWidget getHelperWidget()
```

### margin

```
public ConstraintReference margin(Object marginValue)
```

### margin

```
public ConstraintReference margin(int value)
```

### setBarrierDirection

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

```
public void setBarrierDirection(State.Direction barrierDirection)
```