public class PriorityGoalRow extends ArrayRow


Implements a row containing goals taking in account priorities.

Summary

Public constructors

Public methods

void
abstract void
void
SolverVariable
getPivotCandidate(LinearSystem system, boolean[] avoid)
abstract void
boolean
String
abstract void
updateFromFinalVariable(
    LinearSystem system,
    SolverVariable variable,
    boolean removeFromDefinition
)
abstract void
updateFromRow(LinearSystem system, ArrayRow definition, boolean b)
void
updateFromRow(
    LinearSystem system,
    ArrayRow definition,
    boolean removeFromDefinition
)

Inherited methods

From androidx.constraintlayout.core.ArrayRow
ArrayRow
addError(LinearSystem system, int strength)
ArrayRow
createRowDimensionRatio(
    SolverVariable variableA,
    SolverVariable variableB,
    SolverVariable variableC,
    SolverVariable variableD,
    float ratio
)

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

ArrayRow
createRowEqualDimension(
    float currentWeight,
    float totalWeights,
    float nextWeight,
    SolverVariable variableStartA,
    int marginStartA,
    SolverVariable variableEndA,
    int marginEndA,
    SolverVariable variableStartB,
    int marginStartB,
    SolverVariable variableEndB,
    int marginEndB
)
ArrayRow
createRowEqualMatchDimensions(
    float currentWeight,
    float totalWeights,
    float nextWeight,
    SolverVariable variableStartA,
    SolverVariable variableEndA,
    SolverVariable variableStartB,
    SolverVariable variableEndB
)
ArrayRow
createRowEquals(SolverVariable variable, int value)
ArrayRow
createRowEquals(
    SolverVariable variableA,
    SolverVariable variableB,
    int margin
)
ArrayRow
ArrayRow
createRowGreaterThan(
    SolverVariable variableA,
    SolverVariable variableB,
    SolverVariable slack,
    int margin
)
ArrayRow
createRowLowerThan(
    SolverVariable variableA,
    SolverVariable variableB,
    SolverVariable slack,
    int margin
)
ArrayRow
createRowWithAngle(
    SolverVariable at,
    SolverVariable ab,
    SolverVariable bt,
    SolverVariable bb,
    float angleComponent
)

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

SolverVariable
void

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

SolverVariable
void
void
updateFromFinalVariable(
    LinearSystem system,
    SolverVariable variable,
    boolean removeFromDefinition
)
void
updateFromSynonymVariable(
    LinearSystem system,
    SolverVariable variable,
    boolean removeFromDefinition
)
void

Public constructors

PriorityGoalRow

Added in 1.1.0-alpha13
public PriorityGoalRow(Cache cache)

Public methods

addError

public void addError(SolverVariable error)

addError

public abstract void addError(SolverVariable variable)

clear

public void clear()

getPivotCandidate

public SolverVariable getPivotCandidate(LinearSystem system, boolean[] avoid)

initFromRow

public abstract void initFromRow(LinearSystem.Row row)

isEmpty

public boolean isEmpty()

toString

public String toString()

updateFromFinalVariable

public abstract void updateFromFinalVariable(
    LinearSystem system,
    SolverVariable variable,
    boolean removeFromDefinition
)

updateFromRow

public abstract void updateFromRow(LinearSystem system, ArrayRow definition, boolean b)

updateFromRow

public void updateFromRow(
    LinearSystem system,
    ArrayRow definition,
    boolean removeFromDefinition
)