-
- All Implemented Interfaces:
-
com.brightcove.player.event.Component
@Emits(events = {EventType.REGISTER_PLUGIN})@ListensFor(events = {EventType.DID_SELECT_SOURCE, EventType.DID_SET_VIDEO, EventType.DID_PLAY, EventType.DID_PAUSE, EventType.DID_SEEK_TO, EventType.PROGRESS, EventType.COMPLETED, EventType.ACTIVITY_STOPPED, OmnitureEventType.SET_HEARTBEAT_CONFIG_DATA, OmnitureEventType.COLLECT_LIFECYCLE_DATA, OmnitureEventType.PAUSE_COLLECT_LIFECYCLE_DATA}) public class OmnitureComponent extends AbstractComponent implements Component
Implements an integration with the Adobe Mobile Library for Android. This component will respond to playback events emitted by video players using the Brightcove Native Player for Android, and track the appropriate events via the Media interface for video tracking. For more information on the Media interface, see below: http://microsite.omniture.com/t2/help/en_US/mobile/android/video_qs.html This class also supports the use of Video Heartbeat as an alternative to milestone tracking provided by the above. For information on the use of Video Heartbeat can be found at: http://microsite.omniture.com/t2/help/en_US/sc/appmeasurement/hbvideo/
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public enum
OmnitureComponent.TrackingState
public interface
OmnitureComponent.MediaNameFactory
Provides a simple interface to allow the generation of media names that are tracked inOmniture to be customized.
public class
OmnitureComponent.DefaultMediaNameFactory
Default implementation of MediaNameFactory which follows these steps:
- If video exists and has an ID property as identified by Video.Fields.ID, use it
- Otherwise if given a Source object, presumably the one chosen by the currentSourceSelector implementation, use the URL from that Source
- Otherwise fall back to the DEFAULT_MEDIA_NAME constant value
-
Field Summary
Fields Modifier and Type Field Description public final static String
TAG
public final static String
DEFAULT_PLAYER_NAME
public final static String
DEFAULT_MEDIA_ID
public final static String
VIDEO_ID
public final static String
HEARTBEAT_TRACKING_SERVER
public final static String
HEARTBEAT_CHANNEL
public final static String
HEARTBEAT_OVP
public final static String
HEARTBEAT_APP_VERSION
public final static String
HEARTBEAT_SSL
public final static String
HEARTBEAT_DEBUG_LOGGING
private Media
mediaMeasurement
private String
playerName
private String
playerId
private OmnitureComponent.MediaNameFactory
mediaNameFactory
private Map<String, String>
videoMetadata
-
Constructor Summary
Constructors Constructor Description OmnitureComponent(EventEmitter emitter, Context context, String playerName, String playerId)
For the Omniture component to be able to properly track video playback events in Omniture,the following parameters must be properly specified: OmnitureComponent(EventEmitter emitter, Context context, String playerName, String playerId, BaseVideoView baseVideoView, boolean useHeartbeat)
To support video heartbeat tracking with the omniture plugin, the following parameters mustbe specified:
-
Method Summary
Modifier and Type Method Description Media
getMediaMeasurement()
Retrieves the instance of Media interface used by this Component. void
setMediaMeasurement(Media measure)
Allows the Component-level developer to override the built-in reference to Omniture'sMedia API. String
getPlayerName()
Retrieves the name of the video player provided to the Omniture Component. String
getPlayerId()
Retrieves the unique identifier of the video player provided to the Omniture Component. void
setMediaNameFactory(OmnitureComponent.MediaNameFactory factory)
This method allows a user of the Omniture plugin to override the logic used to generate amedia name used in Omniture video tracking. Map<String, String>
getVideoMetadata()
Retrieves the Video Metadata Map. void
setVideoMetadata(Map<String, String> videoMetadata)
Sets the Video Metadata Map. -
-
Constructor Detail
-
OmnitureComponent
OmnitureComponent(EventEmitter emitter, Context context, String playerName, String playerId)
For the Omniture component to be able to properly track video playback events in Omniture,the following parameters must be properly specified:- Parameters:
emitter
- the EventEmitter used by the current player or applicationcontext
- the Context for the current application (could be the current Activity)playerName
- the name of the video player to be used in video tracking; if set to nullthen the DEFAULT_PLAYER_NAME will be usedplayerId
- the unique identifier of the video player to be used in video tracking
-
OmnitureComponent
OmnitureComponent(EventEmitter emitter, Context context, String playerName, String playerId, BaseVideoView baseVideoView, boolean useHeartbeat)
To support video heartbeat tracking with the omniture plugin, the following parameters mustbe specified:- Parameters:
emitter
- the EventEmitter used by the current player or applicationcontext
- the Context for the current application (could be the current Activity)playerName
- the name of the video player to be used in video tracking; if set to nullthen the DEFAULT_PLAYER_NAME will be usedplayerId
- the unique identifier of the video player to be used in video trackingbaseVideoView
- the BaseVideoView performing media playback in the applicationuseHeartbeat
- the boolean value to toggle the use of video heartbeat
-
-
Method Detail
-
getMediaMeasurement
Media getMediaMeasurement()
Retrieves the instance of Media interface used by this Component.
-
setMediaMeasurement
void setMediaMeasurement(Media measure)
Allows the Component-level developer to override the built-in reference to Omniture'sMedia API. Useful for testing.
- Parameters:
measure
- a new instance of Media, which will override the built-inreference.
-
getPlayerName
String getPlayerName()
Retrieves the name of the video player provided to the Omniture Component.
-
getPlayerId
String getPlayerId()
Retrieves the unique identifier of the video player provided to the Omniture Component.
-
setMediaNameFactory
void setMediaNameFactory(OmnitureComponent.MediaNameFactory factory)
This method allows a user of the Omniture plugin to override the logic used to generate amedia name used in Omniture video tracking. This must be called before the video gets loadedby the player.
- Parameters:
factory
- an implementation of MediaNameFactory
-
getVideoMetadata
Map<String, String> getVideoMetadata()
Retrieves the Video Metadata Map.
-
setVideoMetadata
void setVideoMetadata(Map<String, String> videoMetadata)
Sets the Video Metadata Map.
- Parameters:
videoMetadata
- Adobe Analytics context data
-
-
-
-