/// /// HybridImageSpec.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.image 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.ArrayBuffer import com.margelo.nitro.core.HybridObject /** * A Kotlin class representing the Image HybridObject. * Implement this abstract class to create Kotlin-based instances of Image. */ @DoNotStrip @Keep @Suppress( "KotlinJniMissingFunction", "unused", "RedundantSuppression", "RedundantUnitReturnType", "SimpleRedundantLet", "LocalVariableName", "PropertyName", "PrivatePropertyName", "FunctionName" ) abstract class HybridImageSpec: HybridObject() { // Properties @get:DoNotStrip @get:Keep abstract val width: Double @get:DoNotStrip @get:Keep abstract val height: Double // Methods @DoNotStrip @Keep abstract fun toRawPixelData(allowGpu: Boolean?): RawPixelData @DoNotStrip @Keep abstract fun toRawPixelDataAsync(allowGpu: Boolean?): Promise @DoNotStrip @Keep abstract fun toEncodedImageData(format: ImageFormat, quality: Double?): EncodedImageData @DoNotStrip @Keep abstract fun toEncodedImageDataAsync(format: ImageFormat, quality: Double?): Promise @DoNotStrip @Keep abstract fun resize(width: Double, height: Double): HybridImageSpec @DoNotStrip @Keep abstract fun resizeAsync(width: Double, height: Double): Promise @DoNotStrip @Keep abstract fun rotate(degrees: Double, allowFastFlagRotation: Boolean?): HybridImageSpec @DoNotStrip @Keep abstract fun rotateAsync(degrees: Double, allowFastFlagRotation: Boolean?): Promise @DoNotStrip @Keep abstract fun crop(startX: Double, startY: Double, endX: Double, endY: Double): HybridImageSpec @DoNotStrip @Keep abstract fun cropAsync(startX: Double, startY: Double, endX: Double, endY: Double): Promise @DoNotStrip @Keep abstract fun mirrorHorizontally(): HybridImageSpec @DoNotStrip @Keep abstract fun mirrorHorizontallyAsync(): Promise @DoNotStrip @Keep abstract fun saveToFileAsync(path: String, format: ImageFormat, quality: Double?): Promise @DoNotStrip @Keep abstract fun saveToTemporaryFileAsync(format: ImageFormat, quality: Double?): Promise @DoNotStrip @Keep abstract fun toThumbHash(): ArrayBuffer @DoNotStrip @Keep abstract fun toThumbHashAsync(): Promise @DoNotStrip @Keep abstract fun renderInto(image: HybridImageSpec, x: Double, y: Double, width: Double, height: Double): HybridImageSpec @DoNotStrip @Keep abstract fun renderIntoAsync(image: HybridImageSpec, x: Double, y: Double, width: Double, height: Double): Promise // Default implementation of `HybridObject.toString()` override fun toString(): String { return "[HybridObject Image]" } // C++ backing class @DoNotStrip @Keep protected open class CxxPart(javaPart: HybridImageSpec): HybridObject.CxxPart(javaPart) { // C++ JHybridImageSpec::CxxPart::initHybrid(...) external override fun initHybrid(): HybridData } override fun createCxxPart(): CxxPart { return CxxPart(this) } companion object { protected const val TAG = "HybridImageSpec" } }