package com.example.tis_sep.di

import android.content.Intent
import com.example.core.PspService
import dagger.Module
import dagger.Provides
import dagger.hilt.InstallIn
import dagger.hilt.components.SingletonComponent

@Module
@InstallIn(SingletonComponent::class)
object PspModule {
    @Provides
    fun providePspService(): PspService = object : PspService {
        override fun pay(amount: Double, onMessage: (String) -> Unit) {
            onMessage("Standard: Payment not supported")
        }
        override fun print(text: String, onMessage: (String) -> Unit) {
            onMessage("Standard: Printing not supported")
        }
        override fun createPurchaseIntent(amount: Long): Intent? = null
        override fun decodePosResponse(response: String?): Map<String, Any>? = null
    }
}
