Represents a break (e.g. ad break) included in the main video.
Constructor
Break
new
Break(id, breakClipIds, position)
Parameter
id
string
Unique ID of a break.
breakClipIds
Array of string
List of break clip IDs included in
this break.
Value must not be null.
position
number
Position of this break inside the main video.
Properties
breakClipIds
non-null Array of string
List of break clip IDs included in this break.
duration
(number or undefined)
Duration of break in seconds.
id
string
Unique ID of a break.
isEmbedded
(boolean or undefined)
Indicates whether the break is embedded in the main stream.
isWatched
boolean
Whether a break was watched. This is marked as true when the break begins
to play. A sender can change color of a progress bar marker corresponding
to this break once this field changes from false to true denoting that
the end-user already watched this break.
position
number
Location of the break inside the main video. -1 represents the end of the
main video in seconds.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-18 UTC."],[[["\u003cp\u003eThe \u003ccode\u003echrome.cast.media.Break\u003c/code\u003e class represents an ad break or similar interruption within a main video stream.\u003c/p\u003e\n"],["\u003cp\u003eBreaks are identified by a unique ID and contain a list of break clip IDs, along with their position in the main video.\u003c/p\u003e\n"],["\u003cp\u003eKey properties of a Break include its duration, whether it's embedded within the stream, and if it has been watched by the user.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can use the \u003ccode\u003eBreak\u003c/code\u003e object to manage and track breaks within their Cast-enabled applications.\u003c/p\u003e\n"]]],["The `Break` class represents a video break, such as an ad break, within a main video. It requires an `id`, a list of `breakClipIds`, and a `position`. Key properties include `breakClipIds` (list of clip IDs), `duration` (break length), `id` (unique identifier), `isEmbedded` (embedded status), `isWatched` (watched status, toggled when playback starts), and `position` (location within the video, -1 for the end). The constructor `Break` is used to instantiate breaks, given the id, breakClipIds, and position.\n"],null,["# Class: Break\n\nchrome.[cast](/cast/docs/reference/web_sender/chrome.cast).[media](/cast/docs/reference/web_sender/chrome.cast.media).Break\n===========================================================================================================================\n\nclass static\n\nRepresents a break (e.g. ad break) included in the main video.\n\nConstructor\n-----------\n\n### Break\n\nnew\nBreak(id, breakClipIds, position)\n\n| #### Parameter ||\n|--------------|----------------------------------------------------------------------------------------|\n| id | string Unique ID of a break. |\n| breakClipIds | Array of string List of break clip IDs included in this break. Value must not be null. |\n| position | number Position of this break inside the main video. |\n\nProperties\n----------\n\n### breakClipIds\n\nnon-null Array of string\n\nList of break clip IDs included in this break.\n\n### duration\n\n(number or undefined)\n\nDuration of break in seconds.\n\n### id\n\nstring\n\nUnique ID of a break.\n\n### isEmbedded\n\n(boolean or undefined)\n\nIndicates whether the break is embedded in the main stream.\n\n### isWatched\n\nboolean\n\nWhether a break was watched. This is marked as true when the break begins\nto play. A sender can change color of a progress bar marker corresponding\nto this break once this field changes from false to true denoting that\nthe end-user already watched this break.\n\n### position\n\nnumber\n\nLocation of the break inside the main video. -1 represents the end of the\nmain video in seconds."]]