Class: shaka.ads.SvtaInterstitialTracker

Constructor

new SvtaInterstitialTracker()

Implements:
Source:

Classes

SlotTracker

Members

generation_ :number

Type:
  • number
Source:

pods_ :Map<string, shaka.ads.SvtaInterstitialTracker.PodEntry>

Pods whose slots are carried separately, by id. The first object seen is kept, so the pod state is shared by all its slots.
Type:
Source:

remoteFields_ :WeakMap<Object, !Promise>

Type:
  • WeakMap<Object, !Promise>
Source:

slotFired_ :WeakMap<shaka.extern.AdCreativeSignaling.Slot, !Set<shaka.ads.InterstitialTracker.Event>>

Tracking events already sent for embedded slots. Watching an embedded slot again (e.g. after seeking back) is not a new ad view.
Type:
Source:

slotIds_ :Set<string>

Ids of the standalone slots already seen. Duplicates, e.g. from a manifest update, are not scheduled again, so they are not linked.
Type:
  • Set<string>
Source:

unlinkedSlots_ :Map<string, shaka.extern.AdInterstitial>

Standalone slots not yet linked to a pod, by id. Their pod may arrive later.
Type:
Source:

Methods

attach_(entry, slot)

Parameters:
Name Type Description
entry shaka.ads.SvtaInterstitialTracker.PodEntry
slot shaka.extern.AdInterstitial
Source:

contains_(entry, slot) → {boolean}

Parameters:
Name Type Description
entry shaka.ads.SvtaInterstitialTracker.PodEntry
slot shaka.extern.AdInterstitial
Source:
Returns:
Type
boolean

create(interstitialnon-null, sessionnon-null, sendBeacon, fetch) → {shaka.ads.InterstitialAdSession.Tracker}

Parameters:
Name Type Description
interstitial shaka.extern.AdInterstitial
session shaka.ads.InterstitialAdSession
sendBeacon function(string)
fetch function(string): !shaka.net.NetworkingEngine.PendingRequest
Source:
Returns:
Type
shaka.ads.InterstitialAdSession.Tracker

linkPods(podsnon-null, interstitialsnon-null)

Links slots to the pod whose interval contains them, when the pod and its slots are carried separately (SVTA2053 section 5.2.2). They may arrive in any order, so each new pod or slot is matched against the ones already seen. Slots already nested in a pod are left as they are.
Parameters:
Name Type Description
pods Array<!shaka.ads.SvtaInterstitialParser.StandalonePod>
interstitials Array<shaka.extern.AdInterstitial>
Source:

release()

Request that this object release all internal references.
Implements:
Source:

reset()

Forgets the state of the current asset. Pending responses are discarded, even if the network abort arrives late.
Source:

resolveContainer_(containernon-null, sessionnon-null, fetch) → {Promise}

Resolves each remote container once, when its media is needed. Responses replace the field rather than appending to its inline fallback.
Parameters:
Name Type Description
container shaka.extern.AdCreativeSignaling.Pod | shaka.extern.AdCreativeSignaling.Slot
session shaka.ads.InterstitialAdSession
fetch function(string): !shaka.net.NetworkingEngine.PendingRequest
Source:
Returns:
Type
Promise

Type Definitions

PodEntry

Type:
Source:

PodState

Type:
Source: