All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.cleveradssolutions.gradleplugin.AdaptersImpl.kt Maven / Gradle / Ivy

Go to download

CAS Gradle Plugin provides an easy way to integrate and configure CAS.AI Mediation in your android project.

The newest version!
package com.cleveradssolutions.gradleplugin

internal class AdaptersImpl : CASAdaptersConfig {
    val includedSet = HashSet()

    private fun apply(artifact: Artifact, included: Boolean) {
        if (included) includedSet.add(artifact)
        else includedSet.remove(artifact)
    }

    override var crossPromo: Boolean
        get() = includedSet.contains(Artifact.CROSS_PROMO)
        set(value) = apply(Artifact.CROSS_PROMO, value)

    override var ironSource: Boolean
        get() = includedSet.contains(Artifact.IRONSOURCE)
        set(value) = apply(Artifact.IRONSOURCE, value)

    override var googleAds: Boolean
        get() = includedSet.contains(Artifact.GOOGLE_MOBILE_ADS)
        set(value) = apply(Artifact.GOOGLE_MOBILE_ADS, value)

    override var unityAds: Boolean
        get() = includedSet.contains(Artifact.UNITY_ADS)
        set(value) = apply(Artifact.UNITY_ADS, value)

    override var kidoz: Boolean
        get() = includedSet.contains(Artifact.KIDOZ)
        set(value) = apply(Artifact.KIDOZ, value)

    override var superAwesome: Boolean
        get() = includedSet.contains(Artifact.SUPERAWESOME)
        set(value) = apply(Artifact.SUPERAWESOME, value)

    override var liftoffMonetize: Boolean
        get() = includedSet.contains(Artifact.LIFTOFF_MONETIZE)
        set(value) = apply(Artifact.LIFTOFF_MONETIZE, value)

    override var inMobi: Boolean
        get() = includedSet.contains(Artifact.INMOBI)
        set(value) = apply(Artifact.INMOBI, value)

    override var chartboost: Boolean
        get() = includedSet.contains(Artifact.CHARTBOOST)
        set(value) = apply(Artifact.CHARTBOOST, value)

    override var dtExchange: Boolean
        get() = includedSet.contains(Artifact.DT_EXCHANGE)
        set(value) = apply(Artifact.DT_EXCHANGE, value)

    override var mintegral: Boolean
        get() = includedSet.contains(Artifact.MINTEGRAL)
        set(value) = apply(Artifact.MINTEGRAL, value)

    override var appLovin: Boolean
        get() = includedSet.contains(Artifact.APPLOVIN)
        set(value) = apply(Artifact.APPLOVIN, value)

    override var audienceNetwork: Boolean
        get() = includedSet.contains(Artifact.META_AUDIENCE_NETWORK)
        set(value) = apply(Artifact.META_AUDIENCE_NETWORK, value)

    override var pangle: Boolean
        get() = includedSet.contains(Artifact.PANGLE)
        set(value) = apply(Artifact.PANGLE, value)

    override var yandexAds: Boolean
        get() = includedSet.contains(Artifact.YANDEX_MOBILE_ADS)
        set(value) = apply(Artifact.YANDEX_MOBILE_ADS, value)

    override var bigoAds: Boolean
        get() = includedSet.contains(Artifact.BIGO_ADS)
        set(value) = apply(Artifact.BIGO_ADS, value)

    @BetaAdapter
    override var casExchange: Boolean
        get() = includedSet.contains(Artifact.CAS_EXCHANGE)
        set(value) = apply(Artifact.CAS_EXCHANGE, value)

    @BetaAdapter
    override var ogury: Boolean
        get() = includedSet.contains(Artifact.OGURY)
        set(value) = apply(Artifact.OGURY, value)

    @BetaAdapter
    override var loopMe: Boolean
        get() = includedSet.contains(Artifact.LOOPME)
        set(value) = apply(Artifact.LOOPME, value)

    @BetaAdapter
    override var startIO: Boolean
        get() = includedSet.contains(Artifact.START_IO)
        set(value) = apply(Artifact.START_IO, value)

    @BetaAdapter
    override var madex: Boolean
        get() = includedSet.contains(Artifact.MADEX)
        set(value) = apply(Artifact.MADEX, value)

    @BetaAdapter
    override var hyprMX: Boolean
        get() = includedSet.contains(Artifact.HYPRMX)
        set(value) = apply(Artifact.HYPRMX, value)

    @BetaAdapter
    override var smaato: Boolean
        get() = includedSet.contains(Artifact.SMAATO)
        set(value) = apply(Artifact.SMAATO, value)


    @Deprecated("No longer supported")
    override var myTarget: Boolean = false
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy