package com.blaze.rtnblazesdk import com.facebook.proguard.annotations.DoNotStrip import com.facebook.react.bridge.Promise import com.facebook.react.bridge.ReactApplicationContext import com.facebook.react.bridge.ReactContextBaseJavaModule import com.facebook.react.bridge.ReactMethod import com.facebook.react.bridge.ReactModuleWithSpec import com.facebook.react.bridge.ReadableMap import com.facebook.react.turbomodule.core.interfaces.TurboModule import javax.annotation.Nonnull abstract class NativeBlazeSdkSpec(reactContext: ReactApplicationContext?) : ReactContextBaseJavaModule(reactContext), ReactModuleWithSpec, TurboModule { @Nonnull override fun getName(): String { return NAME } @ReactMethod @DoNotStrip abstract fun init(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun playStory(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun playMoment(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun dismissPlayer(promise: Promise) @DoNotStrip @ReactMethod(isBlockingSynchronousMethod = true) abstract fun isInitialized(): Boolean @ReactMethod @DoNotStrip abstract fun setExternalUserId(externalUserId: String?, promise: Promise) @ReactMethod @DoNotStrip abstract fun playStories(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun playMoments(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun prepareStories(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun prepareMoments(options: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun setDoNotTrack(doNotTrackUser: Boolean, promise: Promise) @ReactMethod @DoNotStrip abstract fun handleUniversalLink(link: String, promise: Promise) @ReactMethod @DoNotStrip abstract fun canHandleUniversalLink(link: String, promise: Promise) @ReactMethod @DoNotStrip abstract fun updateGeoRestriction(geoLocation: String?, promise: Promise) @ReactMethod @DoNotStrip abstract fun canHandlePushNotification(payload: ReadableMap, promise: Promise) @ReactMethod @DoNotStrip abstract fun handleNotificationPayload(payload: ReadableMap, promise: Promise) companion object { const val NAME = "RTNBlazeSdk" } }