ViewTransition

public class ViewTransition
extends Object

java.lang.Object
   ↳ androidx.constraintlayout.motion.widget.ViewTransition


Provides a support for tag it Parses tag it implement the transition it will update ConstraintSet or sets For asynchronous it will create and drive a MotionController.

Summary

Constants

String CONSTRAINT_OVERRIDE

String CUSTOM_ATTRIBUTE

String CUSTOM_METHOD

String KEY_FRAME_SET_TAG

int ONSTATE_ACTION_DOWN

int ONSTATE_ACTION_DOWN_UP

int ONSTATE_ACTION_UP

int ONSTATE_SHARED_VALUE_SET

int ONSTATE_SHARED_VALUE_UNSET

String VIEW_TRANSITION_TAG

Public methods

int getSharedValue()

Gets the SharedValue it will be listening for.

int getSharedValueCurrent()
int getSharedValueID()

Gets the ID of the SharedValue it will be listening for.

int getStateTransition()

Gets the type of transition to listen to.

void setSharedValue(int sharedValue)

sets the SharedValue it will be listening for.

void setSharedValueCurrent(int sharedValueCurrent)
void setSharedValueID(int sharedValueID)

sets the ID of the SharedValue it will be listening for.

void setStateTransition(int stateTransition)

Sets the type of transition to listen to.

String toString()

Inherited methods

Constants

CONSTRAINT_OVERRIDE

public static final String CONSTRAINT_OVERRIDE

Constant Value: "ConstraintOverride"

CUSTOM_ATTRIBUTE

public static final String CUSTOM_ATTRIBUTE

Constant Value: "CustomAttribute"

CUSTOM_METHOD

public static final String CUSTOM_METHOD

Constant Value: "CustomMethod"

KEY_FRAME_SET_TAG

public static final String KEY_FRAME_SET_TAG

Constant Value: "KeyFrameSet"

ONSTATE_ACTION_DOWN

public static final int ONSTATE_ACTION_DOWN

Constant Value: 1 (0x00000001)

ONSTATE_ACTION_DOWN_UP

public static final int ONSTATE_ACTION_DOWN_UP

Constant Value: 3 (0x00000003)

ONSTATE_ACTION_UP

public static final int ONSTATE_ACTION_UP

Constant Value: 2 (0x00000002)

ONSTATE_SHARED_VALUE_SET

public static final int ONSTATE_SHARED_VALUE_SET

Constant Value: 4 (0x00000004)

ONSTATE_SHARED_VALUE_UNSET

public static final int ONSTATE_SHARED_VALUE_UNSET

Constant Value: 5 (0x00000005)

VIEW_TRANSITION_TAG

public static final String VIEW_TRANSITION_TAG

Constant Value: "ViewTransition"

Public methods

getSharedValue

public int getSharedValue ()

Gets the SharedValue it will be listening for.

Returns
int

getSharedValueCurrent

public int getSharedValueCurrent ()

Returns
int

getSharedValueID

public int getSharedValueID ()

Gets the ID of the SharedValue it will be listening for.

Returns
int the id of the shared value

getStateTransition

public int getStateTransition ()

Gets the type of transition to listen to.

Returns
int ONSTATE_TRANSITION_*

setSharedValue

public void setSharedValue (int sharedValue)

sets the SharedValue it will be listening for.

Parameters
sharedValue int

setSharedValueCurrent

public void setSharedValueCurrent (int sharedValueCurrent)

Parameters
sharedValueCurrent int

setSharedValueID

public void setSharedValueID (int sharedValueID)

sets the ID of the SharedValue it will be listening for.

Parameters
sharedValueID int

setStateTransition

public void setStateTransition (int stateTransition)

Sets the type of transition to listen to.

toString

public String toString ()

Returns
String