Skip to main content

Class: AnimationNumberCondition

Defined in: animations/types/AnimationCondition.ts:156

Class for number-based animation conditions.

Extends

  • AnimationConditionWithComparator<number, AnimationConditionNumberComparator>

Constructors

Constructor

new AnimationNumberCondition(inputName, inputConditionComparator, inputConditionValue, invertCondition?): AnimationNumberCondition

Defined in: animations/types/AnimationCondition.ts:103

Creates an instance of AnimationConditionWithComparator.

Parameters

inputName

string

The name of the input used in the condition.

inputConditionComparator

AnimationConditionNumberComparator

The comparator used to compare against the input condition value.

inputConditionValue

number

The value to compare the condition against.

invertCondition?

boolean

Whether to invert the condition result.

Returns

AnimationNumberCondition

Inherited from

AnimationConditionWithComparator< number, AnimationConditionNumberComparator >.constructor

Properties

inputConditionComparator

inputConditionComparator: AnimationConditionNumberComparator

Defined in: animations/types/AnimationCondition.ts:94

The comparator operator used to compare against the input condition value

Inherited from

AnimationConditionWithComparator.inputConditionComparator


inputConditionValue

inputConditionValue: number

Defined in: animations/types/AnimationCondition.ts:90

The value to compare the condition against

Inherited from

AnimationConditionWithComparator.inputConditionValue


inputName

inputName: string

Defined in: animations/types/AnimationCondition.ts:38

The name of the input used in the condition.

Inherited from

AnimationConditionWithComparator.inputName


invertCondition

invertCondition: boolean

Defined in: animations/types/AnimationCondition.ts:42

Whether to invert the condition result.

Inherited from

AnimationConditionWithComparator.invertCondition

Methods

checkCondition()

protected checkCondition(inputValue): boolean

Defined in: animations/types/AnimationCondition.ts:178

Method to check the condition based on the input value.

Parameters

inputValue

number

the value of the input to validate the condition against

Returns

boolean

Whether the condition is met based on the input value.

Overrides

AnimationConditionWithComparator.checkCondition


validateCondition()

protected validateCondition(inputValue): boolean

Defined in: animations/types/AnimationCondition.ts:68

Validates the condition based on the input value and whether to invert the condition.

Parameters

inputValue

number

the value of the input to validate the condition against

Returns

boolean

Whether the condition is met based on the input value.

Inherited from

AnimationConditionWithComparator.validateCondition


validateConditionFromInputs()

validateConditionFromInputs(animationInputs): boolean

Defined in: animations/types/AnimationCondition.ts:165

Method to validate the condition based on all of the animation inputs.

Parameters

animationInputs

AnimationInputs

The animation inputs to validate the condition against.

Returns

boolean

Whether the condition is met based on the animation inputs.

Overrides

AnimationConditionWithComparator.validateConditionFromInputs