Package | com.brightcove.api.modules |
Class | public class ExperienceModule |
Inheritance | ExperienceModule ![]() ![]() |
Method | Defined By | ||
---|---|---|---|
ExperienceModule(module:Object)
Constructor. | ExperienceModule | ||
![]() | addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = true):void [override]
Adds a listener for an event. | APIModule | |
debug(message:String):void
Logs a debug message to the Brightcove Debugger (http://admin.brightcove.com/viewer/BrightcoveDebugger.html). | ExperienceModule | ||
getAdEnabled():Boolean
Returns whether the player is currently ad enabled. | ExperienceModule | ||
getConfiguredPropertiesForID(key:String):Object
Returns the configuration propertues for the specified ID. | ExperienceModule | ||
getElementByID(id:String):Object
Returns a reference to one of the elements in the UI. | ExperienceModule | ||
getElementsByType(type:String):Array
Returns an array of components of a particular type. | ExperienceModule | ||
getEnabled():Boolean
Returns whether the template is currently enabled for user interaction. | ExperienceModule | ||
getExperienceID():Number
Returns the ID of the experience loaded. | ExperienceModule | ||
getExperienceURL():String
Returns the url of the page where the experience is loaded. | ExperienceModule | ||
getHeight():Number
Returns the pixel height of the experience. | ExperienceModule | ||
getLayout():String
Returns the layout loaded from the server. | ExperienceModule | ||
Returns the component API interface for the root element of the experience. | ExperienceModule | ||
getModules():Array
Returns an array of ModuleIdentifier objects that can be used to request references to the loaded module SWFs
in the player. | ExperienceModule | ||
getPlayerName():String
Returns the name given the player in the Brightcove Publishing module. | ExperienceModule | ||
getPlayerParameter(name:String):String
Returns the value of the snippet configuration custom parameter. | ExperienceModule | ||
getPublisherID():Number
Returns the publisher ID for the experience loaded. | ExperienceModule | ||
getReady():Boolean
Returns whether the templateReady event has been fired. | ExperienceModule | ||
getReferrerURL():String
Returns the url of the referrer page where the experience is loaded. | ExperienceModule | ||
getStage():Stage
Returns a reference to the stage if one is available. | ExperienceModule | ||
getTranslation(key:String):String
Returns the player's current translation for the specific key. | ExperienceModule | ||
getUserCountry():String
Returns the user country, if it was detected and if the publisher account has
geo-controls enabled. | ExperienceModule | ||
getWidth():Number
Returns the pixel width of the experience. | ExperienceModule | ||
loadExperience(config:Object):void
Loads a new experience instance into federated shell. | ExperienceModule | ||
![]() | removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void [override]
Removes a listener for an event. | APIModule | |
setEnabled(enable:Boolean):void
Sets whether the template is currently enabled for user interaction. | ExperienceModule | ||
setSize(width:Number, height:Number):void
Sets the pixel dimensions for the experience. | ExperienceModule | ||
unload():void
Destructor method for removing a player. | ExperienceModule |
Event | Summary | Defined By | ||
---|---|---|---|---|
Dispatched when player is added to the stage, if not a part of the display list on load. | ExperienceModule | |||
Dispatched when player enters into fullscreen mode. | ExperienceModule | |||
Dispatched when player exits fullscreen mode. | ExperienceModule | |||
Dispatched when player has loaded its data and is ready for interaction through API. | ExperienceModule | |||
Dispatched when player displays user message dialog for an error that has occurred. | ExperienceModule |
ExperienceModule | () | Constructor |
public function ExperienceModule(module:Object)
Constructor.
Parametersmodule:Object — module to wrap with this API class.
|
debug | () | method |
public function debug(message:String):void
Logs a debug message to the Brightcove Debugger (http://admin.brightcove.com/viewer/BrightcoveDebugger.html).
Parameters
message:String — message to send to the debug window.
|
getAdEnabled | () | method |
public function getAdEnabled():Boolean
Returns whether the player is currently ad enabled. This method only checks for the player and not if the video content is ad enabled or not.
ReturnsBoolean — True if the player is ad enabled.
|
getConfiguredPropertiesForID | () | method |
public function getConfiguredPropertiesForID(key:String):Object
Returns the configuration propertues for the specified ID.
Parameters
key:String — key of the map to retrieve.
|
Object — The map of configured values for the item key.
|
getElementByID | () | method |
public function getElementByID(id:String):Object
Returns a reference to one of the elements in the UI.
Parameters
id:String — ID of the element.
|
Object — A reference to the element.
|
getElementsByType | () | method |
public function getElementsByType(type:String):Array
Returns an array of components of a particular type.
Parameters
type:String — The BEML node name to search for.
|
Array — An array of elements of the specified node type.
|
getEnabled | () | method |
public function getEnabled():Boolean
Returns whether the template is currently enabled for user interaction.
ReturnsBoolean — True if the template is enabled.
|
getExperienceID | () | method |
public function getExperienceID():Number
Returns the ID of the experience loaded.
ReturnsNumber — The ID of the experience loaded.
|
getExperienceURL | () | method |
public function getExperienceURL():String
Returns the url of the page where the experience is loaded.
ReturnsString — The url of the page where the experience is loaded.
|
getHeight | () | method |
public function getHeight():Number
Returns the pixel height of the experience.
ReturnsNumber — The pixel height of the experience.
|
getLayout | () | method |
public function getLayout():String
Returns the layout loaded from the server.
ReturnsString — The BEML defining the experience. This is the BEML as defined from the server.
|
getLayoutRoot | () | method |
public function getLayoutRoot():LayoutBox
Returns the component API interface for the root element of the experience.
ReturnsLayoutBox — The component API interface for the root element.
|
getModules | () | method |
public function getModules():Array
Returns an array of ModuleIdentifier objects that can be used to request references to the loaded module SWFs in the player. Each ModuleIdentifier contains an id and path. The path is the URL to the SWF that was loaded. This can be used to identify the desired SWF to communicate with. The id property can then be used in a call to getElementByID() to retrieve a reference and communicate with the module.
ReturnsArray — An array of objects containing a path to the SWF and the id to be able to retrieve a reference to a
a module through a call to getElementByID().
|
getPlayerName | () | method |
public function getPlayerName():String
Returns the name given the player in the Brightcove Publishing module.
ReturnsString — The name given the player in the Brightcove Publishing module.
|
getPlayerParameter | () | method |
public function getPlayerParameter(name:String):String
Returns the value of the snippet configuration custom parameter.
Parameters
name:String — name of the parameter to retrieve.
|
String |
getPublisherID | () | method |
public function getPublisherID():Number
Returns the publisher ID for the experience loaded.
ReturnsNumber — The publisher ID for the experience loaded.
|
getReady | () | method |
public function getReady():Boolean
Returns whether the templateReady event has been fired.
ReturnsBoolean — True if the templateReady event has been fired.
|
getReferrerURL | () | method |
public function getReferrerURL():String
Returns the url of the referrer page where the experience is loaded.
ReturnsString — The url of the referrer page where the experience is loaded.
|
getStage | () | method |
public function getStage():Stage
Returns a reference to the stage if one is available. See the article, Using getStage to Access Player Configuration Parameters, to learn how to use this method within a container SWF containing a Brightcove player, an embedded component SWF, and the JavaScript-based APIs. This method returns a reference to the Stage. Also see, Creating a Visible Brightcove Plugin to see a code example of this method.
ReturnsStage — A reference to the stage in the player.
|
getTranslation | () | method |
public function getTranslation(key:String):String
Returns the player's current translation for the specific key.
Parameters
key:String — The key for which to retrieve the translation.
|
String — The translation for the specified key, if available to the player.
|
getUserCountry | () | method |
public function getUserCountry():String
Returns the user country, if it was detected and if the publisher account has geo-controls enabled.
ReturnsString — The country code of the user, or null if the country is not available.
|
getWidth | () | method |
public function getWidth():Number
Returns the pixel width of the experience.
ReturnsNumber — The pixel width of the experience.
|
loadExperience | () | method |
public function loadExperience(config:Object):void
Loads a new experience instance into federated shell.
Parameters
config:Object — object containing details about the instance to load.
|
setEnabled | () | method |
public function setEnabled(enable:Boolean):void
Sets whether the template is currently enabled for user interaction.
Parameters
enable:Boolean — if the template should be enabled.
|
setSize | () | method |
public function setSize(width:Number, height:Number):void
Sets the pixel dimensions for the experience.
Parameters
width:Number — pixel width to set the experience to.
| |
height:Number — pixel height to set the experience to.
|
unload | () | method |
public function unload():void
Destructor method for removing a player.
addedToStage | Event |
com.brightcove.api.events.ExperienceEvent
com.brightcove.api.events.ExperienceEvent.ADDED_TO_STAGE
Dispatched when player is added to the stage, if not a part of the display list on load.
The ExperienceEvent.ADDED_TO_STAGE constant defines the value of thetype
property of the event object for a
addedToStage
event.
enterFullScreen | Event |
com.brightcove.api.events.ExperienceEvent
com.brightcove.api.events.ExperienceEvent.ENTER_FULLSCREEN
Dispatched when player enters into fullscreen mode.
The ExperienceEvent.ENTER_FULLSCREEN constant defines the value of thetype
property of the event object for a
enterFullScreen
event.
exitFullScreen | Event |
com.brightcove.api.events.ExperienceEvent
com.brightcove.api.events.ExperienceEvent.EXIT_FULLSCREEN
Dispatched when player exits fullscreen mode.
The ExperienceEvent.EXIT_FULLSCREEN constant defines the value of thetype
property of the event object for a
exitFullScreen
event.
templateReady | Event |
com.brightcove.api.events.ExperienceEvent
com.brightcove.api.events.ExperienceEvent.TEMPLATE_READY
Dispatched when player has loaded its data and is ready for interaction through API.
The ExperienceEvent.TEMPLATE_READY constant defines the value of thetype
property of the event object for a
templateReady
event.
userMessage | Event |
com.brightcove.api.events.ExperienceEvent
com.brightcove.api.events.ExperienceEvent.USER_MESSAGE
Dispatched when player displays user message dialog for an error that has occurred.
The ExperienceEvent.USER_MESSAGE constant defines the value of thetype
property of the event object for a
userMessage
event.