HapticPattern class

Represents a complete haptic pattern with multiple events.

Constructors

HapticPattern({required List<HapticEvent> events})
const
HapticPattern.continuous({required double duration, double intensity = 1.0, double sharpness = 0.5})
Creates a continuous vibration pattern.
factory
HapticPattern.doubleTap({double intensity = 1.0, double sharpness = 0.5, double delay = 0.1})
Creates a double tap haptic pattern.
factory
HapticPattern.heartbeat({double intensity = 1.0, double sharpness = 0.5})
Creates a heartbeat haptic pattern.
factory
HapticPattern.tap({double intensity = 1.0, double sharpness = 0.5})
Creates a single tap haptic pattern.
factory

Properties

events List<HapticEvent>
The list of haptic events in this pattern.
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts this pattern to a JSON-compatible map.
toJsonString() String
Converts this pattern to a JSON string for the platform channel.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited