/// /// HybridClarionRecognizerSpec.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.clarion.recognizer import androidx.annotation.Keep import com.facebook.jni.HybridData import com.facebook.proguard.annotations.DoNotStrip import com.margelo.nitro.core.Promise import com.margelo.nitro.core.HybridObject /** * A Kotlin class representing the ClarionRecognizer HybridObject. * Implement this abstract class to create Kotlin-based instances of ClarionRecognizer. */ @DoNotStrip @Keep @Suppress( "KotlinJniMissingFunction", "unused", "RedundantSuppression", "RedundantUnitReturnType", "SimpleRedundantLet", "LocalVariableName", "PropertyName", "PrivatePropertyName", "FunctionName" ) abstract class HybridClarionRecognizerSpec: HybridObject() { // Properties @get:DoNotStrip @get:Keep abstract val state: String // Methods @DoNotStrip @Keep abstract fun isAvailable(language: String): Promise @DoNotStrip @Keep abstract fun supportedLocales(): Promise> @DoNotStrip @Keep abstract fun prepare(config: NativeRecognizerConfig): Promise @DoNotStrip @Keep abstract fun start(): Promise @DoNotStrip @Keep abstract fun stop(): Promise @DoNotStrip @Keep abstract fun discard(): Promise @DoNotStrip @Keep abstract fun release(): Promise abstract fun addStateListener(listener: (state: String) -> Unit): Double @DoNotStrip @Keep private fun addStateListener_cxx(listener: Func_void_std__string): Double { val __result = addStateListener(listener) return __result } abstract fun addAudioLevelListener(listener: (rms: Double, peak: Double) -> Unit): Double @DoNotStrip @Keep private fun addAudioLevelListener_cxx(listener: Func_void_double_double): Double { val __result = addAudioLevelListener(listener) return __result } abstract fun addPartialListener(listener: (result: NativeTranscriptResult) -> Unit): Double @DoNotStrip @Keep private fun addPartialListener_cxx(listener: Func_void_NativeTranscriptResult): Double { val __result = addPartialListener(listener) return __result } abstract fun addFinalListener(listener: (result: NativeTranscriptResult) -> Unit): Double @DoNotStrip @Keep private fun addFinalListener_cxx(listener: Func_void_NativeTranscriptResult): Double { val __result = addFinalListener(listener) return __result } abstract fun addErrorListener(listener: (error: NativeRecognizerError) -> Unit): Double @DoNotStrip @Keep private fun addErrorListener_cxx(listener: Func_void_NativeRecognizerError): Double { val __result = addErrorListener(listener) return __result } @DoNotStrip @Keep abstract fun removeListener(id: Double): Unit @DoNotStrip @Keep abstract fun removeAllListeners(): Unit // Default implementation of `HybridObject.toString()` override fun toString(): String { return "[HybridObject ClarionRecognizer]" } // C++ backing class @DoNotStrip @Keep protected open class CxxPart(javaPart: HybridClarionRecognizerSpec): HybridObject.CxxPart(javaPart) { // C++ JHybridClarionRecognizerSpec::CxxPart::initHybrid(...) external override fun initHybrid(): HybridData } override fun createCxxPart(): CxxPart { return CxxPart(this) } companion object { protected const val TAG = "HybridClarionRecognizerSpec" } }