-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Syncing changes from private repository
- Loading branch information
1 parent
1cfdbb7
commit 6e391b9
Showing
44 changed files
with
1,121 additions
and
907 deletions.
There are no files selected for viewing
Binary file not shown.
84 changes: 37 additions & 47 deletions
84
...artboost/mediation/unity/aps/APSBridge.kt → Android~/src/APSBridge.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,37 @@ | ||
package com.chartboost.mediation.unity.aps | ||
|
||
import android.content.Context | ||
import com.chartboost.mediation.amazonpublisherservicesadapter.AmazonPublisherServicesAdapter | ||
import kotlin.coroutines.resume | ||
import kotlin.coroutines.suspendCoroutine | ||
|
||
class APSBridge { | ||
|
||
companion object { | ||
|
||
private var preBiddingListener: AmazonPublisherServicesAdapter.PreBiddingListener? = null | ||
|
||
@JvmStatic | ||
fun setupPreBiddingListener(consumer: APSPreBidConsumer){ | ||
preBiddingListener = object : AmazonPublisherServicesAdapter.PreBiddingListener { | ||
override suspend fun onPreBid(context: Context, request: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidRequest): Result<AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidAdInfo> { | ||
return suspendCoroutine { continuation -> | ||
consumer.onPreBid(request, object: APSPreBidCompletion { | ||
override fun completion(preBidAdInfo: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidAdInfo) { | ||
continuation.resume(Result.success(preBidAdInfo)) | ||
} | ||
}) | ||
} | ||
} | ||
} | ||
AmazonPublisherServicesAdapter.preBiddingListener = preBiddingListener; | ||
} | ||
|
||
@JvmStatic | ||
fun removePreBiddingListener() | ||
{ | ||
preBiddingListener = null; | ||
AmazonPublisherServicesAdapter.preBiddingListener = null; | ||
} | ||
|
||
@JvmStatic | ||
fun setTestMode(testMode: Boolean){ | ||
AmazonPublisherServicesAdapter.testMode = testMode; | ||
} | ||
|
||
@JvmStatic | ||
fun getTestMode(): Boolean { | ||
return AmazonPublisherServicesAdapter.testMode; | ||
} | ||
} | ||
} | ||
package com.chartboost.mediation.unity.adapter.aps | ||
|
||
import android.content.Context | ||
import com.chartboost.mediation.amazonpublisherservicesadapter.AmazonPublisherServicesAdapter | ||
import kotlin.coroutines.resume | ||
import kotlin.coroutines.suspendCoroutine | ||
|
||
class APSBridge { | ||
|
||
companion object { | ||
|
||
private var preBiddingListener: AmazonPublisherServicesAdapter.PreBiddingListener? = null | ||
|
||
@JvmStatic | ||
fun setupPreBiddingListener(consumer: APSPreBidConsumer){ | ||
preBiddingListener = object : AmazonPublisherServicesAdapter.PreBiddingListener { | ||
override suspend fun onPreBid(context: Context, request: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidRequest): Result<AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidAdInfo> { | ||
return suspendCoroutine { continuation -> | ||
consumer.onPreBid(request, object: APSPreBidCompletion { | ||
override fun completion(preBidAdInfo: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidAdInfo) { | ||
continuation.resume(Result.success(preBidAdInfo)) | ||
} | ||
}) | ||
} | ||
} | ||
} | ||
AmazonPublisherServicesAdapter.preBiddingListener = preBiddingListener; | ||
} | ||
|
||
@JvmStatic | ||
fun removePreBiddingListener() | ||
{ | ||
preBiddingListener = null; | ||
AmazonPublisherServicesAdapter.preBiddingListener = null; | ||
} | ||
} | ||
} |
3 changes: 1 addition & 2 deletions
3
...ediation/unity/aps/APSPreBidCompletion.kt → Android~/src/APSPreBidCompletion.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
package com.chartboost.mediation.unity.aps | ||
package com.chartboost.mediation.unity.adapter.aps | ||
|
||
import com.chartboost.mediation.amazonpublisherservicesadapter.AmazonPublisherServicesAdapter | ||
|
||
interface APSPreBidCompletion { | ||
fun completion(preBidAdInfo: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidAdInfo) | ||
} |
4 changes: 1 addition & 3 deletions
4
.../mediation/unity/aps/APSPreBidConsumer.kt → Android~/src/APSPreBidConsumer.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
package com.chartboost.mediation.unity.aps | ||
package com.chartboost.mediation.unity.adapter.aps | ||
|
||
import com.chartboost.mediation.amazonpublisherservicesadapter.AmazonPublisherServicesAdapter | ||
import com.chartboost.mediation.unity.aps.APSPreBidCompletion | ||
|
||
interface APSPreBidConsumer { | ||
fun onPreBid(request: AmazonPublisherServicesAdapter.AmazonPublisherServicesAdapterPreBidRequest, completion: APSPreBidCompletion) | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,41 @@ | ||
# Changelog | ||
All notable changes to this project will be documented in this file using the standards as defined at [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0). | ||
|
||
### Version 4.0.1 *(20204-03-27)* | ||
Bug Fixes: | ||
|
||
- Added `<androidPackage spec="com.iabtcf:iabtcf-decoder:2.0.10"/>` to `AmazonPublisherServicesAdapterDependencies.xml` | ||
|
||
### Version 4.0.0 *(2024-03-21)* | ||
First version of the Chartboost Mediation Unity SDK - Amazon Publisher Services Adapter. | ||
|
||
This package requires the APS Unity Plugin to be integrated in the project in order to be used. | ||
|
||
New: | ||
|
||
- Added `AmazonPublisherServicesAdapter` class. | ||
- Added `TestMode` mode to setup APS test mode. | ||
- Added `VerboseLogging` to modify adapter logging leve. | ||
- Added `PreBiddingListener` class and property to handle publisher based pre-bidding. | ||
- Added `AmazonSettings` struct to pass required data to the Chartboost Mediation SDK. | ||
|
||
Compatible with the following native Android and iOS SDK Versions: | ||
|
||
* Android: Amazon Publisher Services `com.amazon.android:aps-sdk:9.9.+` | ||
* iOS: `AmazonPublisherServicesSDK ~> 4.8.0` | ||
# Changelog | ||
All notable changes to this project will be documented in this file using the standards as defined at [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0). | ||
|
||
### Version 5.0.0 *(2024-08-08)* | ||
|
||
#Added | ||
- Support for the following 'Amazon Publisher Services' dependencies. Notice adapter dependencies are optimistic and any patches and hot-fixes will be automatically picked up.: | ||
* Android: `com.chartboost:chartboost-mediation-adapter-amazon-publisher-services:5.9.10.+` | ||
* iOS: `ChartboostMediationAdapterAmazonPublisherServices ~> ~> 5.4.9.0` | ||
|
||
- The following properties have been added in `AmazonPublisherServicesAdapter.cs` | ||
* `string AdapterUnityVersion` | ||
* `string AdapterNativeVersion` | ||
* `string PartnerSDKVersion` | ||
* `string PartnerIdentifier` | ||
* `string PartnerDisplayName` | ||
* `bool TestMode` | ||
* `bool VerboseLogging` | ||
|
||
### Version 4.0.1 *(2024-03-27)* | ||
Bug Fixes: | ||
|
||
- Added `<androidPackage spec="com.iabtcf:iabtcf-decoder:2.0.10"/>` to `AmazonPublisherServicesAdapterDependencies.xml` | ||
|
||
### Version 4.0.0 *(2024-03-21)* | ||
First version of the Chartboost Mediation Unity SDK - Amazon Publisher Services Adapter. | ||
|
||
This package requires the APS Unity Plugin to be integrated in the project in order to be used. | ||
|
||
New: | ||
|
||
- Added `AmazonPublisherServicesAdapter` class. | ||
- Added `TestMode` mode to setup APS test mode. | ||
- Added `VerboseLogging` to modify adapter logging leve. | ||
- Added `PreBiddingListener` class and property to handle publisher based pre-bidding. | ||
- Added `AmazonSettings` struct to pass required data to the Chartboost Mediation SDK. | ||
|
||
Compatible with the following native Android and iOS SDK Versions: | ||
|
||
* Android: Amazon Publisher Services `com.amazon.android:aps-sdk:9.9.+` | ||
* iOS: `AmazonPublisherServicesSDK ~> 4.8.0` |
45 changes: 23 additions & 22 deletions
45
Chartboost.CSharp.Mediation.Unity.Adapter.AmazonPublisherServices.nuspec
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<package> | ||
<metadata> | ||
<id>Chartboost.CSharp.Mediation.Unity.Adapter.AmazonPublisherServices</id> | ||
<version>4.0.1</version> | ||
<title>Chartboost Mediation - Amazon Publisher Services Adapter</title> | ||
<description>The Chartboost Mediation Unity SDK Amazon Publisher Services Ad Adapter.</description> | ||
<authors>Chartboost</authors> | ||
<owners>Chartboost</owners> | ||
<license type="file">LICENSE.md</license> | ||
<readme>README.md</readme> | ||
<projectUrl>https://www.chartboost.com/mediate</projectUrl> | ||
<copyright>Copyright 2024</copyright> | ||
<tags>Chartboost, Ads, Mediation, Unity, AmazonPublisherServices, Adapter,cs</tags> | ||
<repository type="git" url="https://github.com/ChartBoost/chartboost-mediation-unity-adapter-amazon-publisher-services"/> | ||
<dependencies> | ||
<dependency id="Chartboost.CSharp.Mediation.Unity" version="4.9.0" /> | ||
<dependency id="Chartboost.CSharp.Threading.Unity" version="1.0.0" /> | ||
<dependency id="Chartboost.CSharp.Utilities.Unity" version="1.0.0" /> | ||
</dependencies> | ||
</metadata> | ||
</package> | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<package> | ||
<metadata> | ||
<id>Chartboost.CSharp.Mediation.Unity.Adapter.AmazonPublisherServices</id> | ||
<version>5.0.0</version> | ||
<title>Chartboost Mediation Adapter - Amazon Publisher Services Adapter</title> | ||
<description>The Chartboost Mediation Unity SDK Ad Adapter for Amazon Publisher Services.</description> | ||
<authors>Chartboost</authors> | ||
<owners>Chartboost</owners> | ||
<license type="file">LICENSE.md</license> | ||
<readme>README.md</readme> | ||
<projectUrl>https://www.chartboost.com/mediate</projectUrl> | ||
<copyright>Copyright 2024</copyright> | ||
<tags>Chartboost, Ads, Mediation, Unity, Adapter, AmazonPublisherServices, cs</tags> | ||
<repository type="git" url="https://github.com/ChartBoost/chartboost-mediation-unity-adapter-amazon-publisher-services"/> | ||
<dependencies> | ||
<dependency id="Chartboost.CSharp.Mediation.Unity" version="5.0.0" /> | ||
<dependency id="Chartboost.CSharp.Threading.Unity" version="1.0.1" /> | ||
<dependency id="Chartboost.CSharp.Utilities.Unity" version="1.0.1" /> | ||
<dependency id="Chartboost.CSharp.Logging.Unity" version="1.0.0" /> | ||
</dependencies> | ||
</metadata> | ||
</package> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.