
plugins {
    id("com.android.application")
    id("org.jetbrains.kotlin.android")
    id("org.jetbrains.kotlin.kapt")
}

android {
    namespace = "io.scanbot.example"
    compileSdk = 35

    defaultConfig {
        applicationId = "io.scanbot.example.sdk.rtu.android"
        targetSdk = 35
        minSdk = 21
        versionCode = 1
        versionName = "1.0"

        ndk {
            abiFilters "armeabi-v7a", "arm64-v8a"
            // Please add "x86" and "x86_64" if you would like to test on an emulator
            // or if you need to support some rare devices with the Intel Atom architecture.
        }
    }

    buildTypes {
        named("debug") {
            // set this to `false` to allow debugging and run a "non-release" build
            minifyEnabled = false
            debuggable = true
        }
        named("release") {
            // set this to `false` to allow debugging and run a "non-release" build
            minifyEnabled = true
            debuggable = true
        }
    }

    kotlin {
        jvmToolchain(17)
    }

    buildFeatures {
        viewBinding = true
        buildConfig = true
    }

    packagingOptions {
        exclude "META-INF/LICENSE.txt"
        exclude "META-INF/LICENSE"
        exclude "META-INF/NOTICE.txt"
        exclude "META-INF/NOTICE"
        exclude "META-INF/DEPENDENCIES"
    }
}

kapt {
    generateStubs = true
}

configurations {
    compile.exclude group: "org.jetbrains", module: "annotations"
}

dependencies {
    implementation("androidx.appcompat:appcompat:1.6.1")
    implementation("com.squareup.picasso:picasso:2.71828")
    implementation("androidx.constraintlayout:constraintlayout:2.1.4")
    implementation("androidx.constraintlayout:constraintlayout-solver:2.0.4")
    implementation("androidx.recyclerview:recyclerview:1.3.2")
    implementation("com.google.android.material:material:1.9.0")

    def coroutines_version = "1.7.3"
    implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_version")
    implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines_version")

    def scanbotSdkVersion = "7.1.1"

    implementation("io.scanbot:sdk-package-4:$scanbotSdkVersion")
    implementation("io.scanbot:sdk-package-ui:$scanbotSdkVersion")
    implementation("io.scanbot:rtu-ui-v2-bundle:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use the Generic Document Recognizer feature
    implementation("io.scanbot:sdk-documentdata-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use the Document Quality Analyzer feature
    implementation("io.scanbot:sdk-multitasktext-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use data scanner feature
    implementation("io.scanbot:sdk-textpattern-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use Medical Certificate scanner feature
    implementation("io.scanbot:sdk-mc-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use Credit Card Scanner feature
    implementation("io.scanbot:sdk-creditcard-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use EHIC scanner feature
    implementation("io.scanbot:sdk-ehic-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use MRZ scanner feature
    implementation("io.scanbot:sdk-mrz-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use Check recognizer feature
    implementation("io.scanbot:sdk-check-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use ImageProcessor feature on ML assets. See comment in Application class.
    implementation("io.scanbot:sdk-ml-imageprocessor-assets:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use Pdfium processor for import export of pdfs. See comment in Application class.
    implementation("io.scanbot:bundle-sdk-pdfium:$scanbotSdkVersion")

    // This dependency is only needed if you plan to use the encryption feature
    implementation("io.scanbot:bundle-sdk-crypto-persistence:$scanbotSdkVersion")
}
