React Native OTVPlayer

Namespace: OTVPlayerWithInsight

OTVPlayerWithInsight

OTVPlayerWithInsight is the extension of OTVPlayer which receives Insight agent as param to collect user's statistics.

Namespaces

props

Methods

staticOTVPlayerWithInsight.setLiveContent(content)

Sets the current live content information.

Name Type Description
content object

data required to play live content

Example
otvplayerWithInsight.current.setLiveContent({
      genre: ["drama"],
      scrambled: true,
      bitrates: [1000000, 2000000, 5000000],
      duration: null,
      uri: 'https://BigBuckBunny.mpd',
      channelId: "CHANNEL1",
      channelName: "Channel One",
      eventId: "123456789",
      eventName: "News",
      type: "LIVE",
    });

staticOTVPlayerWithInsight.setUserInfo(userInfo)

Sets the current user information.

Name Type Description
userInfo object

user information to be passed to set user details

Example
otvplayerWithInsight.current.setUserInfo({
        userId: "123455",
        accountId: "A12B32",
        fullName: "John Doe",
        gender: "male",
        age: 23,
        ageRange: "20-25",
        category: "Junior",
        street: "275 Sacramento Street",
        city: "San Francisco",
        state: "CA",
        postCode: "94111",
        country: "US",
      });

staticOTVPlayerWithInsight.setVodContent(content)

Sets the current vod content information.

Name Type Description
content object

data required to play vod content

Example
otvplayerWithInsight.current.setVodContent({
    contentId: "416781",
    contentName: "test content",
    genre: ["drama"],
    scrambled: true,
    bitrates: [1000000, 2000000, 5000000],
    duration: 1000,
    uri: 'https://BigBuckBunny.mpd',
  });