benxu.AppPlatform.Ads.Core 3.0.4

dotnet add package benxu.AppPlatform.Ads.Core --version 3.0.4
                    
NuGet\Install-Package benxu.AppPlatform.Ads.Core -Version 3.0.4
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="benxu.AppPlatform.Ads.Core" Version="3.0.4" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="benxu.AppPlatform.Ads.Core" Version="3.0.4" />
                    
Directory.Packages.props
<PackageReference Include="benxu.AppPlatform.Ads.Core" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add benxu.AppPlatform.Ads.Core --version 3.0.4
                    
#r "nuget: benxu.AppPlatform.Ads.Core, 3.0.4"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package benxu.AppPlatform.Ads.Core@3.0.4
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=benxu.AppPlatform.Ads.Core&version=3.0.4
                    
Install as a Cake Addin
#tool nuget:?package=benxu.AppPlatform.Ads.Core&version=3.0.4
                    
Install as a Cake Tool

benxu.AppPlatform.Ads.Core

廣告服務抽象層,定義所有廣告類型的核心介面。

功能

  • ✅ 廣告服務主介面(IAdService
  • ✅ Banner 廣告介面(IBannerAdService
  • ✅ Interstitial 廣告介面(IInterstitialAdService
  • ✅ Rewarded 廣告介面(IRewardedAdService)- 預留
  • ✅ Premium 用戶廣告隱藏支援
  • ✅ 三種廣告模式:Production / Test / Mock

安裝

dotnet add package benxu.AppPlatform.Ads.Core

核心介面

IAdService

public interface IAdService
{
    bool IsPremium { get; }
    bool IsEnabled { get; }
    void SetIsPremium(bool isPremium);
    void SetEnabled(bool enabled);
    Task InitializeAsync();
}

廣告模式

public enum AdMode
{
    Production,  // 正式廣告
    Test,        // Google 官方測試廣告
    Mock         // 模擬模式(不呼叫 SDK)
}
Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on benxu.AppPlatform.Ads.Core:

Package Downloads
benxu.AppPlatform.BlazorUI

Blazor UI component library for benxu App Platform - Provides reusable UI components.

benxu.AppPlatform.Ads.AdMob

AdMob implementation for ad services in .NET MAUI Blazor applications. Supports Banner, Interstitial and Rewarded ads with Mock mode for testing.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.0.4 29 2/14/2026
3.0.3 29 2/14/2026