YouTubePHP Documentation

CdnSettings extends Part
in package

This file is generated from spec/discovery.json (YouTube Data API v3, revision 20260924) by tools/generate.php. Do not edit it by hand - run `composer spec:build` instead.

Brief description of the live stream cdn settings.

Tags
since
1.0.0

Table of Contents

Constants

FRAME_RATE_30FPS  : mixed = '30fps'
A `frameRate` of `30fps`.
FRAME_RATE_60FPS  : mixed = '60fps'
A `frameRate` of `60fps`.
FRAME_RATE_VARIABLE  : mixed = 'variable'
A `frameRate` of `variable`.
INGESTION_TYPE_DASH  : mixed = 'dash'
A `ingestionType` of `dash`.
INGESTION_TYPE_HLS  : mixed = 'hls'
A `ingestionType` of `hls`.
INGESTION_TYPE_RTMP  : mixed = 'rtmp'
A `ingestionType` of `rtmp`.
INGESTION_TYPE_WEBRTC  : mixed = 'webrtc'
A `ingestionType` of `webrtc`.
RESOLUTION_1080P  : mixed = '1080p'
A `resolution` of `1080p`.
RESOLUTION_1440P  : mixed = '1440p'
A `resolution` of `1440p`.
RESOLUTION_2160P  : mixed = '2160p'
A `resolution` of `2160p`.
RESOLUTION_240P  : mixed = '240p'
A `resolution` of `240p`.
RESOLUTION_360P  : mixed = '360p'
A `resolution` of `360p`.
RESOLUTION_480P  : mixed = '480p'
A `resolution` of `480p`.
RESOLUTION_720P  : mixed = '720p'
A `resolution` of `720p`.
RESOLUTION_VARIABLE  : mixed = 'variable'
A `resolution` of `variable`.

Properties

$format  : string|null
$frameRate  : string|null
$ingestionInfo  : IngestionInfo|null
$ingestionType  : string|null
$resolution  : string|null
$casts  : array<string, string>
Attribute name => type token (`"LiveChatMessageSnippet"`, `"Array of Thumbnail"`, `"Map of VideoLocalization"`), used to hydrate nested objects into parts.
$dates  : array<int, string>
Attribute names holding RFC 3339 timestamps, read back as {@see CarbonImmutable}. They are stored and serialised as the strings YouTube sent.
$youtube  : ?YouTube

Methods

__construct()  : mixed
__debugInfo()  : array<string, mixed>
__get()  : mixed
__isset()  : bool
__set()  : void
__toString()  : string
__unset()  : void
attributeExists()  : bool
fill()  : void
getAttribute()  : mixed
getCasts()  : array<string, string>
getDates()  : array<int, string>
getRawAttribute()  : mixed
Reads straight from the attribute bag, skipping the `get{Key}Attribute` hook.
getRawAttributes()  : array<string, mixed>
getYouTube()  : YouTube
The client this part came from.
jsonSerialize()  : array<string, mixed>
The payload this part would be sent back to YouTube as: nested parts and collections flattened, timestamps as RFC 3339 strings.
offsetExists()  : bool
offsetGet()  : mixed
offsetSet()  : void
offsetUnset()  : void
setAttribute()  : void
factory()  : Factory
Builds another part from the same client - for nested objects.
setRawAttribute()  : void
Writes straight to the attribute bag, skipping the `set{Key}Attribute` hook and any cast. For use *inside* a mutator, which would otherwise have no way to store its shaped value without recursing through {@see setAttribute()}.

Constants

FRAME_RATE_30FPS

A `frameRate` of `30fps`.

public mixed FRAME_RATE_30FPS = '30fps'

FRAME_RATE_60FPS

A `frameRate` of `60fps`.

public mixed FRAME_RATE_60FPS = '60fps'

FRAME_RATE_VARIABLE

A `frameRate` of `variable`.

public mixed FRAME_RATE_VARIABLE = 'variable'

INGESTION_TYPE_DASH

A `ingestionType` of `dash`.

public mixed INGESTION_TYPE_DASH = 'dash'

INGESTION_TYPE_HLS

A `ingestionType` of `hls`.

public mixed INGESTION_TYPE_HLS = 'hls'

INGESTION_TYPE_RTMP

A `ingestionType` of `rtmp`.

public mixed INGESTION_TYPE_RTMP = 'rtmp'

INGESTION_TYPE_WEBRTC

A `ingestionType` of `webrtc`.

public mixed INGESTION_TYPE_WEBRTC = 'webrtc'

RESOLUTION_1080P

A `resolution` of `1080p`.

public mixed RESOLUTION_1080P = '1080p'

RESOLUTION_1440P

A `resolution` of `1440p`.

public mixed RESOLUTION_1440P = '1440p'

RESOLUTION_2160P

A `resolution` of `2160p`.

public mixed RESOLUTION_2160P = '2160p'

RESOLUTION_240P

A `resolution` of `240p`.

public mixed RESOLUTION_240P = '240p'

RESOLUTION_360P

A `resolution` of `360p`.

public mixed RESOLUTION_360P = '360p'

RESOLUTION_480P

A `resolution` of `480p`.

public mixed RESOLUTION_480P = '480p'

RESOLUTION_720P

A `resolution` of `720p`.

public mixed RESOLUTION_720P = '720p'

RESOLUTION_VARIABLE

A `resolution` of `variable`.

public mixed RESOLUTION_VARIABLE = 'variable'

Properties

$format

public string|null $format

Deprecated. The format of the video stream that you are sending to Youtube.

$frameRate

public string|null $frameRate

The frame rate of the inbound video data. One of the FRAME_RATE_* constants.

$ingestionInfo

public IngestionInfo|null $ingestionInfo

The ingestionInfo object contains information that YouTube provides that you need to transmit your RTMP or HTTP stream to YouTube.

$ingestionType

public string|null $ingestionType

The method or protocol used to transmit the video stream. One of the INGESTION_TYPE_* constants.

$resolution

public string|null $resolution

The resolution of the inbound video data. One of the RESOLUTION_* constants.

$casts

Attribute name => type token (`"LiveChatMessageSnippet"`, `"Array of Thumbnail"`, `"Map of VideoLocalization"`), used to hydrate nested objects into parts.

protected array<string, string> $casts = ['ingestionInfo' => 'IngestionInfo']

$dates

Attribute names holding RFC 3339 timestamps, read back as {@see CarbonImmutable}. They are stored and serialised as the strings YouTube sent.

protected array<int, string> $dates = []

Methods

__construct()

public __construct([YouTube|null $youtube = null ][, array<string, mixed>|object $attributes = [] ]) : mixed
Parameters
$youtube : YouTube|null = null

The client, for behaviour that calls the API.

$attributes : array<string, mixed>|object = []

__debugInfo()

public __debugInfo() : array<string, mixed>
Return values
array<string, mixed>

__get()

public __get(string $name) : mixed
Parameters
$name : string

__isset()

public __isset(string $name) : bool
Parameters
$name : string
Return values
bool

__set()

public __set(string $name, mixed $value) : void
Parameters
$name : string
$value : mixed

__toString()

public __toString() : string
Return values
string

__unset()

public __unset(string $name) : void
Parameters
$name : string

attributeExists()

public attributeExists(string $key) : bool
Parameters
$key : string
Return values
bool

fill()

public fill(array<string, mixed> $attributes) : void
Parameters
$attributes : array<string, mixed>

getAttribute()

public getAttribute(string $key) : mixed
Parameters
$key : string

getCasts()

public getCasts() : array<string, string>
Return values
array<string, string>

getDates()

public getDates() : array<int, string>
Return values
array<int, string>

getRawAttribute()

Reads straight from the attribute bag, skipping the `get{Key}Attribute` hook.

public getRawAttribute(string $key) : mixed
Parameters
$key : string

getRawAttributes()

public getRawAttributes() : array<string, mixed>
Return values
array<string, mixed>

getYouTube()

The client this part came from.

public getYouTube() : YouTube
Tags
throws
LogicException

When the part was built without one.

Return values
YouTube

jsonSerialize()

The payload this part would be sent back to YouTube as: nested parts and collections flattened, timestamps as RFC 3339 strings.

public jsonSerialize() : array<string, mixed>
Return values
array<string, mixed>

offsetExists()

public offsetExists(mixed $offset) : bool
Parameters
$offset : mixed
Return values
bool

offsetGet()

public offsetGet(mixed $offset) : mixed
Parameters
$offset : mixed

offsetSet()

public offsetSet(mixed $offset, mixed $value) : void
Parameters
$offset : mixed
$value : mixed

offsetUnset()

public offsetUnset(mixed $offset) : void
Parameters
$offset : mixed

setAttribute()

public setAttribute(string $key, mixed $value) : void
Parameters
$key : string
$value : mixed

factory()

Builds another part from the same client - for nested objects.

protected factory() : Factory
Return values
Factory

setRawAttribute()

Writes straight to the attribute bag, skipping the `set{Key}Attribute` hook and any cast. For use *inside* a mutator, which would otherwise have no way to store its shaped value without recursing through {@see setAttribute()}.

protected setRawAttribute(string $key, mixed $value) : void
Parameters
$key : string
$value : mixed
On this page

Search results