/// /// HapticEvent.kt /// This file was generated by nitrogen. DO NOT MODIFY THIS FILE. /// https://github.com/mrousavy/nitro /// Copyright © Marc Rousavy @ Margelo /// package com.margelo.nitro.haptic import androidx.annotation.Keep import com.facebook.proguard.annotations.DoNotStrip import java.util.Objects /** * Represents the JavaScript object/struct "HapticEvent". */ @DoNotStrip @Keep data class HapticEvent( @DoNotStrip @Keep val eventType: HapticEventType, @DoNotStrip @Keep val time: Double, @DoNotStrip @Keep val eventDuration: Double?, @DoNotStrip @Keep val parameters: HapticParameters? ) { /* primary constructor */ override fun equals(other: Any?): Boolean { if (this === other) return true if (other !is HapticEvent) return false return Objects.deepEquals(this.eventType, other.eventType) && Objects.deepEquals(this.time, other.time) && Objects.deepEquals(this.eventDuration, other.eventDuration) && Objects.deepEquals(this.parameters, other.parameters) } override fun hashCode(): Int { return arrayOf( eventType, time, eventDuration, parameters ).contentDeepHashCode() } companion object { /** * Constructor called from C++ */ @DoNotStrip @Keep @Suppress("unused") @JvmStatic private fun fromCpp(eventType: HapticEventType, time: Double, eventDuration: Double?, parameters: HapticParameters?): HapticEvent { return HapticEvent(eventType, time, eventDuration, parameters) } } }