registerRenderer

abstract suspend fun registerRenderer(name: String, factory: (AdRenderer.ServiceLocator) -> AdRenderer)

Registers a custom ad renderer.

With this method, you can register your custom AdRenderer type to display advertisements.

Parameters

name

The key by which the SDK match the advert with your renderer. It must be the same as the key received from the server.

factory

The factory method that creates an instance of your AdRenderer. You can use AdRenderer.ServiceLocator as a service locator or DI container when creating a renderer.