BannerEventListener class mixin
Banner life cycle goes as follows:
- onLoaded Called when the banner is loaded and ready to be shown. If this goes wrong, the onFailedToLoad is called.
- onImpression Ad Is Shown and ready to be Clicked.
- onClick A Creative of the Ad is clicked. It can be a call to action creative or not.
- onOpen Happens after onClick. If it opens an Intent in the App to see the advertisement.
- onClose That Intent was closed and now we are back to your app.
- onFailedToLoad When this occurs, the factory marks the object for deletion and then invokes this event with an R89LoadError. You can use that to know what happened.
- Implemented types
Constructors
- BannerEventListener.callbacks({AdLayoutChangeCallback? onLayoutChangeCallback, AdVoidCallback? onClickCallback, AdFailedToLoadCallback? onFailedToLoadCallback, AdVoidCallback? onImpressionCallback, AdVoidCallback? onLoadedCallback, AdVoidCallback? onOpenCallback, AdVoidCallback? onCloseCallback})
-
The helper factory constructor,
which can be used to listen directly and in-place to specific events
without the need to extend, mix, or implement BannerEventListener.
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onClick(
) → void -
Called when an ad is clicked.
override
-
onClose(
) → void -
Called when the Intent is returned.
override
-
onFailedToLoad(
String message) → void -
Called when an ad is failed to load.
override
-
onImpression(
) → void -
Called when an ad is shown on the screen for the first time.
override
-
onLayoutChange(
int width, int height) → void - Called when something happens to the layout make sure to check if width and height are the same as the last time.
-
onLoaded(
) → void -
Called when an ad is loaded.
override
-
onOpen(
) → void -
Called when an ad starts an Intent.
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited