คลาส GCKMediaInformation
คลาสที่รวบรวมข้อมูลเกี่ยวกับรายการสื่อ
รับค่า NSObject, <NSCopying> และ <NSSecureCoding>
- (instancetype) initWithContentID: |
|
(NSString *) |
contentID |
streamType: |
|
(GCKMediaStreamType) |
streamType |
contentType: |
|
(NSString *) |
contentType |
metadata: |
|
(nullable GCKMediaMetadata *) |
metadata |
adBreaks: |
|
(nullable NSArray< GCKAdBreakInfo * > *) |
adBreaks |
adBreakClips: |
|
(nullable NSArray< GCKAdBreakClipInfo * > *) |
adBreakClips |
streamDuration: |
|
(NSTimeInterval) |
streamDuration |
mediaTracks: |
|
(nullable NSArray< GCKMediaTrack * > *) |
mediaTracks |
textTrackStyle: |
|
(nullable GCKMediaTextTrackStyle *) |
textTrackStyle |
customData: |
|
(nullable id) |
customData |
|
|
| |
เลิกใช้งานแล้ว
ใช้ GCKMediaInformationBuilder เพื่อเริ่มต้นออบเจ็กต์ GCKMediaInformation
- Parameters
-
contentID | The content ID. |
streamType | The stream type. |
contentType | The content (MIME) type. |
metadata | The media item metadata. |
adBreaks | The list of ad breaks in this content. |
adBreakClips | The list of ad break clips in this content. |
streamDuration | The stream duration. |
mediaTracks | The media tracks, if any, otherwise nil . |
textTrackStyle | The text track style, if any, otherwise nil . |
customData | The custom application-specific data. Must either be an object that can be serialized to JSON using NSJSONSerialization, or nil . |
- Since
- 4.3
- (instancetype) initWithContentID: |
|
(NSString *) |
contentID |
streamType: |
|
(GCKMediaStreamType) |
streamType |
contentType: |
|
(NSString *) |
contentType |
metadata: |
|
(nullable GCKMediaMetadata *) |
metadata |
streamDuration: |
|
(NSTimeInterval) |
streamDuration |
mediaTracks: |
|
(nullable NSArray< GCKMediaTrack * > *) |
mediaTracks |
textTrackStyle: |
|
(nullable GCKMediaTextTrackStyle *) |
textTrackStyle |
customData: |
|
(nullable id) |
customData |
|
|
| |
เลิกใช้งานแล้ว
ใช้ GCKMediaInformationBuilder เพื่อเริ่มต้นออบเจ็กต์ GCKMediaInformation
- Parameters
-
contentID | The content ID. |
streamType | The stream type. |
contentType | The content (MIME) type. |
metadata | The media item metadata. |
streamDuration | The stream duration. |
mediaTracks | The media tracks, if any, otherwise nil . |
textTrackStyle | The text track style, if any, otherwise nil . |
customData | The custom application-specific data. Must either be an object that can be serialized to JSON using NSJSONSerialization, or nil . |
- (nullable GCKMediaTrack *) mediaTrackWithID: |
|
(NSInteger) |
trackID |
|
ค้นหาแทร็กสื่อที่มีรหัสแทร็กที่ระบุ
- Parameters
-
trackID | The media track ID. |
- การคืนสินค้า
- ออบเจ็กต์ GCKMediaTrack ที่ตรงกัน หรือ
nil
หากไม่มีแทร็กสื่อที่มีรหัสที่ระบุ
รหัสเนื้อหาสำหรับสตรีมนี้
URL ของเนื้อหาที่จะเล่น
- Since
- 4.3.4
- (NSString*) contentType |
|
readnonatomiccopy |
รายการช่วงพักโฆษณาในเนื้อหานี้
รายการคลิปช่วงพักโฆษณาในเนื้อหานี้
- Since
- 3.3
- (NSTimeInterval) streamDuration |
|
readnonatomicassign |
ความยาวของสตรีมเป็นวินาที หรือ INFINITY
หากเป็นสตรีมแบบสด
รูปแบบแทร็กข้อความสำหรับสตรีมนี้
Deep Link ของสื่อที่ Google Assistant ใช้ (หากมี)
- Since
- 4.0
- (NSTimeInterval) startAbsoluteTime |
|
readnonatomicassign |
เวลา Epoch ในหน่วยวินาทีของเวลาเริ่มต้นสตรีมแบบสด
สำหรับสตรีมแบบสดที่มีเวลาเริ่มต้นที่ทราบ เช่น รายการทีวีสดหรือเกมกีฬา เวลานี้จะเริ่มตามเวลา Epoch มิเช่นนั้น จะเป็นเวลาเริ่มต้นของช่วงที่ค้นหาได้แบบเรียลไทม์เมื่อเริ่มการสตรีม
- Since
- 4.4.1
รูปแบบของกลุ่มเสียง HLS
- Since
- 4.6.0
รูปแบบของกลุ่มวิดีโอ HLS
- Since
- 4.6.0
ข้อมูลที่กำหนดเอง (หากมี)
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2023-12-02 UTC
[null,null,["อัปเดตล่าสุด 2023-12-02 UTC"],[[["The `GCKMediaInformation` class stores details about a media item, like content ID, URL, type, metadata, stream duration, and more."],["It includes properties for ad breaks, ad break clips, media tracks, text track style, and custom data."],["Two deprecated initializers are listed, with a recommendation to use `GCKMediaInformationBuilder` instead."],["The `mediaTrackWithID:` method helps find a specific media track using its ID."],["Several properties provide detailed information about the media, such as content ID, URL, stream type, metadata, ad breaks, stream duration, and custom data."]]],["The `GCKMediaInformation` class aggregates data about a media item, including its `contentID`, `contentURL`, `streamType`, and `contentType`. It also includes media metadata, such as `metadata`, `adBreaks`, `adBreakClips`, `streamDuration`, and `mediaTracks`. Actions include initializing the media item using deprecated methods, searching for a media track by its ID with `mediaTrackWithID:`, and accessing properties, which includes properties like the `textTrackStyle`, `entity`, `VMAP`, `startAbsoluteTime`, `hlsSegmentFormat`, `hlsVideoSegmentFormat`, and custom data (`customData`).\n"]]