Class Triggers
- java.lang.Object
-
- com.brightcove.ssai.tracking.timed.Triggers
-
public class Triggers extends java.lang.Object
Contains helper static methods related toTimedTrackingTrigger
.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<com.brightcove.ssai.tracking.timed.TimedTrackingTrigger>
create(EventEmitter eventEmitter)
Crates theTimedTrackingTrigger
s of the supportedTrackingEvent
s.static void
emitTrackingEvent(EventEmitter eventEmitter, java.util.List<TrackingEvent> trackingEvents, Ad<?> ad, TrackingType trackingType)
Helper method to emit eachTrackingEvent
from a list.static boolean
isValueInBetween(long value, long min, long max)
Checks whether a value is in between the min and the max.
-
-
-
Method Detail
-
create
public static java.util.List<com.brightcove.ssai.tracking.timed.TimedTrackingTrigger> create(@NonNull EventEmitter eventEmitter)
Crates theTimedTrackingTrigger
s of the supportedTrackingEvent
s.- Returns:
- A
List
of theTimedTrackingTrigger
s
-
isValueInBetween
public static boolean isValueInBetween(long value, long min, long max)
Checks whether a value is in between the min and the max. The min value is inclusive and the max value is exclusive, in fewer words [min, max).- Parameters:
value
- the value to check.min
- the minimum value.max
- the maximum value.- Returns:
- true if value is in between [min, max], false otherwise.
-
emitTrackingEvent
public static void emitTrackingEvent(@NonNull EventEmitter eventEmitter, @NonNull java.util.List<TrackingEvent> trackingEvents, @NonNull Ad<?> ad, @NonNull TrackingType trackingType)
Helper method to emit eachTrackingEvent
from a list.- Parameters:
eventEmitter
- EventEmitter used to emit the TrackingEvents.trackingEvents
- TrackingEvents to be emitted.ad
- The ad being tracked.trackingType
- The tracking type for this event.
-
-