AdBannerWidget class
Banner广告Widget
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- AdBannerWidget
Constructors
-
AdBannerWidget({Key? key, required String posId, double width = 375, double height = 60, bool isVisible = true, bool? mutedIfCan, double? volume, bool? bidNotify, String? scenarioId, bool? useSurfaceView, bool? enableMixedMode, bool? harmonyNativeRender, Map<
String, dynamic> ? extraParams, VoidCallback? onAdLoaded, dynamic onAdError(String error)?, VoidCallback? onAdClicked, VoidCallback? onAdClosed, dynamic onRenderSuccess(double width, double height)?, dynamic onRenderFail(String error)?, dynamic onEcpmInfo(Map<String, dynamic> ecpmData)?, VoidCallback? onMixedLayout}) -
const
Properties
- bidNotify → bool?
-
是否开启竞价结果回传(聚合功能)
final
- enableMixedMode → bool?
-
启用Banner混出信息流(聚合功能)
final
-
extraParams
→ Map<
String, dynamic> ? -
扩展参数
final
- harmonyNativeRender → bool?
-
HarmonyOS 直连穿山甲时使用原生自渲染 Banner。
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
高度
final
- isVisible → bool
-
是否可见
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- mutedIfCan → bool?
-
是否静音播放(聚合功能)
final
- onAdClicked → VoidCallback?
-
点击回调
final
- onAdClosed → VoidCallback?
-
关闭回调
final
- onAdError → dynamic Function(String error)?
-
错误回调
final
- onAdLoaded → VoidCallback?
-
加载回调
final
-
onEcpmInfo
→ dynamic Function(Map<
String, dynamic> ecpmData)? -
ECPM信息回调
final
- onMixedLayout → VoidCallback?
-
混出信息流布局回调
final
- onRenderFail → dynamic Function(String error)?
-
渲染失败回调
final
- onRenderSuccess → dynamic Function(double width, double height)?
-
渲染成功回调
final
- posId → String
-
广告位ID
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scenarioId → String?
-
场景ID(聚合功能)
final
- useSurfaceView → bool?
-
是否使用SurfaceView(仅Android)
final
- volume → double?
-
音量大小 0.0-1.0(仅Android)
final
- width → double
-
宽度
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< AdBannerWidget> -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited