tech.carpentum.sdk.payment.internal.generated.model.SettlementMethodJsonAdapter.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of payment-client-v2 Show documentation
Show all versions of payment-client-v2 Show documentation
Carpentum Payment system Java SDK
The newest version!
//THE FILE IS GENERATED, DO NOT MODIFY IT MANUALLY!!!
package tech.carpentum.sdk.payment.internal.generated.model;
import tech.carpentum.sdk.payment.model.SettlementMethod
import tech.carpentum.sdk.payment.model.SettlementMethod.PaymentMethodCode
import com.squareup.moshi.JsonAdapter
import com.squareup.moshi.Moshi
import com.squareup.moshi.adapters.PolymorphicJsonAdapterFactory
import java.lang.reflect.Type
class SettlementMethodJsonAdapter : JsonAdapter.Factory {
override fun create(type: Type, annotations: MutableSet, moshi: Moshi): JsonAdapter<*>? {
return PolymorphicJsonAdapterFactory
.of(SettlementMethod::class.java, SettlementMethod.DISCRIMINATOR)
.withSubtype(SettlementCryptoTransferMethodImpl::class.java, PaymentMethodCode.CRYPTO_TRANSFER.toString())
.create(type, annotations, moshi)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy