Packagecom.adobe.ane.stageAd
Classpublic class StageAdEvent
InheritanceStageAdEvent Inheritance flash.events.Event

StageBannerAd and StageFullscreenAd objects dispatch a StageAdEvent whenever a change in the iAd occurs due to loading, unloading or user initiated actions.



Public Properties
 PropertyDefined By
  message : String
[read-only] In an adLoadFail event, specifies the details of the reason why the ad failed to load.
StageAdEvent
  willLeaveApplication : Boolean
[read-only] In an adActionStart event, specifies whether the action that is about to start will cause the Application to go into the background.
StageAdEvent
Public Methods
 MethodDefined By
  
StageAdEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, willLeave:Boolean = false, message:String)
Creates a StageAdEvent object that contains information about the location of the device.
StageAdEvent
  
clone():Event
[override] Creates a copy of the StageAdEvent object and sets the value of each property to match that of the original.
StageAdEvent
  
toString():String
[override] Returns a string that contains all the properties of the StageAdEvent object.
StageAdEvent
Public Constants
 ConstantDefined By
  AD_ACTION_COMPLETE : String = adActionComplete
[static] Defines the value of the type property of a StageAdEvent event object.
StageAdEvent
  AD_ACTION_START : String = adActionStart
[static] Defines the value of the type property of a StageAdEvent event object.
StageAdEvent
  AD_LOAD_COMPLETE : String = adLoadComplete
[static] Defines the value of the type property of a StageAdEvent event object.
StageAdEvent
  AD_LOAD_FAIL : String = adLoadFail
[static] Defines the value of the type property of a StageAdEvent event object.
StageAdEvent
  AD_UNLOAD : String = adUnload
[static] Defines the value of the type property of a StageAdEvent event object.
StageAdEvent
Property Detail
messageproperty
message:String  [read-only]

In an adLoadFail event, specifies the details of the reason why the ad failed to load. For all other types of StageAdEvent, this property is always an empty string and has no significance.


Implementation
    public function get message():String
willLeaveApplicationproperty 
willLeaveApplication:Boolean  [read-only]

In an adActionStart event, specifies whether the action that is about to start will cause the Application to go into the background. For all other types of StageAdEvent, this property is always false and has no significance.

When this property is false, disable activities that require user interaction while the action is executing, as the applications UI will be covered by the ad action. For example, a game might pause its game play until the user finishes watching the advertisement.


Implementation
    public function get willLeaveApplication():Boolean
Constructor Detail
StageAdEvent()Constructor
public function StageAdEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, willLeave:Boolean = false, message:String)

Creates a StageAdEvent object that contains information about the location of the device. Event objects are passed as parameters to event listeners.

Parameters
type:String — Specifies the type of the event. Event listeners can access this information through the inherited type property.
 
bubbles:Boolean (default = false) — Indicates whether the event is a bubbling event. Event listeners can access this information through the inherited bubbles property.
 
cancelable:Boolean (default = false) — Determines whether the event object can be canceled. Event listeners can access this information through the inherited cancelable property.
 
willLeave:Boolean (default = false) — Indicates whether another application will be launched to execute the action.
 
message:String — Contains details specific to the event.
Method Detail
clone()method
override public function clone():Event

Creates a copy of the StageAdEvent object and sets the value of each property to match that of the original.

Returns
Event
toString()method 
override public function toString():String

Returns a string that contains all the properties of the StageAdEvent object. The string is in the following format:

[StageAdEvent type=value bubbles=value cancelable=value willLeaveApplication=value message=value]

Returns
String — A string that contains all the properties of the StageAdEvent object.
Constant Detail
AD_ACTION_COMPLETEConstant
public static const AD_ACTION_COMPLETE:String = adActionComplete

Defines the value of the type property of a StageAdEvent event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
currentTargetThe object that is actively processing the event object with an event listener.
targetThe StageBannerAd or StageFullscreenAd object receiving data.
willLeaveApplicationfalse
messageempty String

AD_ACTION_STARTConstant 
public static const AD_ACTION_START:String = adActionStart

Defines the value of the type property of a StageAdEvent event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; the action initiated by the user interaction cannot be cancelled by calling preventDefault().
currentTargetThe object that is actively processing the event object with an event listener.
targetThe StageBannerAd or StageFullscreenAd object receiving data.
willLeaveApplicationWhether the action that is about to start will cause the Application to go into the background
messageempty String

AD_LOAD_COMPLETEConstant 
public static const AD_LOAD_COMPLETE:String = adLoadComplete

Defines the value of the type property of a StageAdEvent event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
currentTargetThe object that is actively processing the event object with an event listener.
targetThe StageBannerAd or StageFullscreenAd object receiving data.
willLeaveApplicationfalse
messageempty String

AD_LOAD_FAILConstant 
public static const AD_LOAD_FAIL:String = adLoadFail

Defines the value of the type property of a StageAdEvent event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
currentTargetThe object that is actively processing the event object with an event listener.
targetThe StageBannerAd or StageFullscreenAd object receiving data.
willLeaveApplicationfalse
messageThe details of the reason why the ad failed to load

AD_UNLOADConstant 
public static const AD_UNLOAD:String = adUnload

Defines the value of the type property of a StageAdEvent event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
currentTargetThe object that is actively processing the event object with an event listener.
targetThe StageBannerAd or StageFullscreenAd object receiving data.
willLeaveApplicationfalse
messageempty String