/// /// HybridOneBackgroundTasksSpec.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.one import androidx.annotation.Keep import com.facebook.jni.HybridData import com.facebook.proguard.annotations.DoNotStrip import dalvik.annotation.optimization.FastNative import com.margelo.nitro.core.Promise import com.margelo.nitro.core.HybridObject /** * A Kotlin class representing the OneBackgroundTasks HybridObject. * Implement this abstract class to create Kotlin-based instances of OneBackgroundTasks. */ @DoNotStrip @Keep @Suppress( "KotlinJniMissingFunction", "unused", "RedundantSuppression", "RedundantUnitReturnType", "SimpleRedundantLet", "LocalVariableName", "PropertyName", "PrivatePropertyName", "FunctionName" ) abstract class HybridOneBackgroundTasksSpec: HybridObject() { // Properties // Methods @DoNotStrip @Keep abstract fun submit(identifier: String, earliestBeginDateMs: Double?, requiresNetworkConnectivity: Boolean?, requiresExternalPower: Boolean?): Promise @DoNotStrip @Keep abstract fun getPending(): Promise> @DoNotStrip @Keep abstract fun cancel(identifier: String): Unit abstract fun addTaskListener(onLaunch: (invocation: BackgroundTaskInvocation) -> Unit, onExpire: (executionId: String) -> Unit): () -> Unit @DoNotStrip @Keep private fun addTaskListener_cxx(onLaunch: Func_void_BackgroundTaskInvocation, onExpire: Func_void_std__string): Func_void { val __result = addTaskListener(onLaunch, onExpire) return Func_void_java(__result) } @DoNotStrip @Keep abstract fun complete(executionId: String, success: Boolean): Unit // Default implementation of `HybridObject.toString()` override fun toString(): String { return "[HybridObject OneBackgroundTasks]" } // C++ backing class @DoNotStrip @Keep protected open class CxxPart(javaPart: HybridOneBackgroundTasksSpec): HybridObject.CxxPart(javaPart) { // C++ JHybridOneBackgroundTasksSpec::CxxPart::initHybrid(...) @FastNative external override fun initHybrid(): HybridData } override fun createCxxPart(): CxxPart { return CxxPart(this) } companion object { protected const val TAG = "HybridOneBackgroundTasksSpec" } }