public class KeyAttributes extends Key


Defines container for a key frame of for storing KeyAttributes. KeyAttributes change post layout values of a view.

Summary

Constants

static final int

Public constructors

Public methods

void

Defines method to add a a view to splines derived form this key frame.

Key

Clone this KeyAttributes

Key
copy(Key src)

Copy the key

void
void
load(Context context, AttributeSet attrs)
void

create the interpolations associated with this KeyAttribute

void
setValue(String tag, Object value)

Set the value associated with this tag

Inherited Constants

From androidx.constraintlayout.motion.widget.Key
static final String
ALPHA = "alpha"
static final String
CURVEFIT = "curveFit"
static final String
CUSTOM = "CUSTOM"
static final String
ELEVATION = "elevation"
static final String
MOTIONPROGRESS = "motionProgress"
static final String
PIVOT_X = "transformPivotX"
static final String
PIVOT_Y = "transformPivotY"
static final String
PROGRESS = "progress"
static final String
ROTATION = "rotation"
static final String
ROTATION_X = "rotationX"
static final String
ROTATION_Y = "rotationY"
static final String
SCALE_X = "scaleX"
static final String
SCALE_Y = "scaleY"
static final String
TRANSITIONEASING = "transitionEasing"
static final String
TRANSITION_PATH_ROTATE = "transitionPathRotate"
static final String
TRANSLATION_X = "translationX"
static final String
TRANSLATION_Y = "translationY"
static final String
TRANSLATION_Z = "translationZ"
static final String
VISIBILITY = "visibility"
static final String
WAVE_OFFSET = "waveOffset"
static final String
WAVE_PERIOD = "wavePeriod"
static final String
WAVE_PHASE = "wavePhase"
static final String
WAVE_VARIES_BY = "waveVariesBy"

Inherited fields

From androidx.constraintlayout.motion.widget.Key
static int
int

Inherited methods

From androidx.constraintlayout.motion.widget.Key
int

Gets the current frame position

void

sets the frame position

Key
setViewId(int id)

set the id of the view

Constants

KEY_TYPE

Added in 2.2.0
public static final int KEY_TYPE = 1

Public constructors

KeyAttributes

Added in 2.2.0
public KeyAttributes()

Public methods

addValues

Added in 2.2.0
public void addValues(HashMap<StringViewSpline> splines)

Defines method to add a a view to splines derived form this key frame. The values are written to the spline

Parameters
HashMap<StringViewSpline> splines

splines to write values to

clone

Added in 2.2.0
public Key clone()

Clone this KeyAttributes

Returns
Key

copy

public Key copy(Key src)

Copy the key

Parameters
Key src

to be copied

Returns
Key

self

getAttributeNames

Added in 2.2.0
public void getAttributeNames(HashSet<String> attributes)

load

Added in 2.2.0
public void load(Context context, AttributeSet attrs)

setInterpolation

public void setInterpolation(HashMap<StringInteger> interpolation)

create the interpolations associated with this KeyAttribute

Parameters
HashMap<StringInteger> interpolation

will be added to with keyAttributes

setValue

Added in 2.2.0
public void setValue(String tag, Object value)

Set the value associated with this tag

Parameters
String tag
Object value