# ArrayRow

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

*** ** * ** ***

<br />

```
class ArrayRow
```

<br />

Known direct subclasses [GoalRow](https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/GoalRow), [PriorityGoalRow](https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/PriorityGoalRow)

|---|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/GoalRow` |   |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/PriorityGoalRow` | Implements a row containing goals taking in account priorities. |

*** ** * ** ***

## Summary

| ### Nested types |
|---|
| `interface https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow.ArrayRowVariables` |

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#ArrayRow()()` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#ArrayRow(androidx.constraintlayout.core.Cache)(cache: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/Cache!)` |

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#addError(androidx.constraintlayout.core.SolverVariable)(error: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!)` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#addError(androidx.constraintlayout.core.LinearSystem,int)(system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!, strength: 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/core/ArrayRow#clear()()` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowDimensionRatio(androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,float)( variableA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableC: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableD: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Create a constraint to express `A = B + (C - D)` \* ratio We use this for ratio, where for example `Right = Left + (Bottom - Top) * percent` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowEqualDimension(float,float,float,androidx.constraintlayout.core.SolverVariable,int,androidx.constraintlayout.core.SolverVariable,int,androidx.constraintlayout.core.SolverVariable,int,androidx.constraintlayout.core.SolverVariable,int)( currentWeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, totalWeights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, nextWeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, variableStartA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, marginStartA: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, variableEndA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, marginEndA: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, variableStartB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, marginStartB: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, variableEndB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, marginEndB: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowEqualMatchDimensions(float,float,float,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable)( currentWeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, totalWeights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, nextWeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, variableStartA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableEndA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableStartB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableEndB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable! )` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowEquals(androidx.constraintlayout.core.SolverVariable,int)(variable: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowEquals(androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,int)( variableA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowGreaterThan(androidx.constraintlayout.core.SolverVariable,int,androidx.constraintlayout.core.SolverVariable)(a: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, b: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, slack: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!)` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowGreaterThan(androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,int)( variableA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, slack: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowLowerThan(androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,int)( variableA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, variableB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, slack: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, margin: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#createRowWithAngle(androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,androidx.constraintlayout.core.SolverVariable,float)( at: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, ab: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, bt: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, bb: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, angleComponent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Create a constraint to express At + (Ab-At)/2 = Bt + (Bb-Bt)/2 - angle |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#getKey()()` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#getPivotCandidate(androidx.constraintlayout.core.LinearSystem,boolean[])(system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!, avoid: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html>!)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#initFromRow(androidx.constraintlayout.core.LinearSystem.Row)(row: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem.Row!)` Used to initiate a goal from a given row (to see if we can remove an extra var) |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#isEmpty()()` |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#pickPivot(androidx.constraintlayout.core.SolverVariable)(exclude: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!)` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#reset()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#toString()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#updateFromFinalVariable(androidx.constraintlayout.core.LinearSystem,androidx.constraintlayout.core.SolverVariable,boolean)( system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!, variable: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, removeFromDefinition: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html )` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#updateFromRow(androidx.constraintlayout.core.LinearSystem,androidx.constraintlayout.core.ArrayRow,boolean)( system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!, definition: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!, removeFromDefinition: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html )` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#updateFromSynonymVariable(androidx.constraintlayout.core.LinearSystem,androidx.constraintlayout.core.SolverVariable,boolean)( system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!, variable: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!, removeFromDefinition: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html )` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#updateFromSystem(androidx.constraintlayout.core.LinearSystem)(system: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/LinearSystem!)` |

| ### Public properties |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow.ArrayRowVariables!` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow#variables()` |

## Public constructors

### ArrayRow

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

```
ArrayRow()
```

### ArrayRow

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

```
ArrayRow(cache: Cache!)
```

## Public functions

### addError

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

```
fun addError(error: SolverVariable!): Unit
```

### addError

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

```
fun addError(system: LinearSystem!, strength: Int): ArrayRow!
```

### clear

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

```
fun clear(): Unit
```

### createRowDimensionRatio

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

```
fun createRowDimensionRatio(
    variableA: SolverVariable!,
    variableB: SolverVariable!,
    variableC: SolverVariable!,
    variableD: SolverVariable!,
    ratio: Float
): ArrayRow!
```

Create a constraint to express `A = B + (C - D)` \* ratio We use this for ratio, where for example `Right = Left + (Bottom - Top) * percent`

| Parameters |
|---|---|
| `variableA: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | variable A |
| `variableB: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | variable B |
| `variableC: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | variable C |
| `variableD: https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/SolverVariable!` | variable D |
| `ratio: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | ratio between AB and CD |

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/core/ArrayRow!` | the row |

### createRowEqualDimension

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

```
fun createRowEqualDimension(
    currentWeight: Float,
    totalWeights: Float,
    nextWeight: Float,
    variableStartA: SolverVariable!,
    marginStartA: Int,
    variableEndA: SolverVariable!,
    marginEndA: Int,
    variableStartB: SolverVariable!,
    marginStartB: Int,
    variableEndB: SolverVariable!,
    marginEndB: Int
): ArrayRow!
```

### createRowEqualMatchDimensions

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

```
fun createRowEqualMatchDimensions(
    currentWeight: Float,
    totalWeights: Float,
    nextWeight: Float,
    variableStartA: SolverVariable!,
    variableEndA: SolverVariable!,
    variableStartB: SolverVariable!,
    variableEndB: SolverVariable!
): ArrayRow!
```

### createRowEquals

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

```
fun createRowEquals(variable: SolverVariable!, value: Int): ArrayRow!
```

### createRowEquals

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

```
fun createRowEquals(
    variableA: SolverVariable!,
    variableB: SolverVariable!,
    margin: Int
): ArrayRow!
```

### createRowGreaterThan

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

```
fun createRowGreaterThan(a: SolverVariable!, b: Int, slack: SolverVariable!): ArrayRow!
```

### createRowGreaterThan

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

```
fun createRowGreaterThan(
    variableA: SolverVariable!,
    variableB: SolverVariable!,
    slack: SolverVariable!,
    margin: Int
): ArrayRow!
```

### createRowLowerThan

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

```
fun createRowLowerThan(
    variableA: SolverVariable!,
    variableB: SolverVariable!,
    slack: SolverVariable!,
    margin: Int
): ArrayRow!
```

### createRowWithAngle

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

```
fun createRowWithAngle(
    at: SolverVariable!,
    ab: SolverVariable!,
    bt: SolverVariable!,
    bb: SolverVariable!,
    angleComponent: Float
): ArrayRow!
```

Create a constraint to express At + (Ab-At)/2 = Bt + (Bb-Bt)/2 - angle

### getKey

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

```
fun getKey(): SolverVariable!
```

### getPivotCandidate

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

```
fun getPivotCandidate(system: LinearSystem!, avoid: BooleanArray<Boolean>!): SolverVariable!
```

### initFromRow

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

```
fun initFromRow(row: LinearSystem.Row!): Unit
```

Used to initiate a goal from a given row (to see if we can remove an extra var)

### isEmpty

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

```
fun isEmpty(): Boolean
```

### pickPivot

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

```
fun pickPivot(exclude: SolverVariable!): SolverVariable!
```

### reset

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

```
fun reset(): Unit
```

### toString

```
fun toString(): String!
```

### updateFromFinalVariable

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

```
fun updateFromFinalVariable(
    system: LinearSystem!,
    variable: SolverVariable!,
    removeFromDefinition: Boolean
): Unit
```

### updateFromRow

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

```
fun updateFromRow(
    system: LinearSystem!,
    definition: ArrayRow!,
    removeFromDefinition: Boolean
): Unit
```

### updateFromSynonymVariable

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

```
fun updateFromSynonymVariable(
    system: LinearSystem!,
    variable: SolverVariable!,
    removeFromDefinition: Boolean
): Unit
```

### updateFromSystem

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

```
fun updateFromSystem(system: LinearSystem!): Unit
```

## Public properties

### variables

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

```
val variables: ArrayRow.ArrayRowVariables!
```