Class: Google::Apis::YoutubeV3::VideoSnippet

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/youtube_v3/classes.rb,
lib/google/apis/youtube_v3/representations.rb,
lib/google/apis/youtube_v3/representations.rb

Overview

Basic details about a video, including title, description, uploader, thumbnails and category.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ VideoSnippet

Returns a new instance of VideoSnippet.



8340
8341
8342
# File 'lib/google/apis/youtube_v3/classes.rb', line 8340

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#category_idString

The YouTube video category associated with the video. Corresponds to the JSON property categoryId

Returns:

  • (String)


8280
8281
8282
# File 'lib/google/apis/youtube_v3/classes.rb', line 8280

def category_id
  @category_id
end

#channel_idString

The ID that YouTube uses to uniquely identify the channel that the video was uploaded to. Corresponds to the JSON property channelId

Returns:

  • (String)


8286
8287
8288
# File 'lib/google/apis/youtube_v3/classes.rb', line 8286

def channel_id
  @channel_id
end

#channel_titleString

Channel title for the channel that the video belongs to. Corresponds to the JSON property channelTitle

Returns:

  • (String)


8291
8292
8293
# File 'lib/google/apis/youtube_v3/classes.rb', line 8291

def channel_title
  @channel_title
end

#default_audio_languageString

The default_audio_language property specifies the language spoken in the video' s default audio track. Corresponds to the JSON property defaultAudioLanguage

Returns:

  • (String)


8297
8298
8299
# File 'lib/google/apis/youtube_v3/classes.rb', line 8297

def default_audio_language
  @default_audio_language
end

#default_languageString

The language of the videos's default snippet. Corresponds to the JSON property defaultLanguage

Returns:

  • (String)


8302
8303
8304
# File 'lib/google/apis/youtube_v3/classes.rb', line 8302

def default_language
  @default_language
end

#descriptionString

The video's description. @mutable youtube.videos.insert youtube.videos.update Corresponds to the JSON property description

Returns:

  • (String)


8307
8308
8309
# File 'lib/google/apis/youtube_v3/classes.rb', line 8307

def description
  @description
end

#live_broadcast_contentString

Indicates if the video is an upcoming/active live broadcast. Or it's "none" if the video is not an upcoming/active live broadcast. Corresponds to the JSON property liveBroadcastContent

Returns:

  • (String)


8313
8314
8315
# File 'lib/google/apis/youtube_v3/classes.rb', line 8313

def live_broadcast_content
  @live_broadcast_content
end

#localizedGoogle::Apis::YoutubeV3::VideoLocalization

Localized versions of certain video properties (e.g. title). Corresponds to the JSON property localized



8318
8319
8320
# File 'lib/google/apis/youtube_v3/classes.rb', line 8318

def localized
  @localized
end

#published_atDateTime

The date and time when the video was uploaded. Corresponds to the JSON property publishedAt

Returns:

  • (DateTime)


8323
8324
8325
# File 'lib/google/apis/youtube_v3/classes.rb', line 8323

def published_at
  @published_at
end

#tagsArray<String>

A list of keyword tags associated with the video. Tags may contain spaces. Corresponds to the JSON property tags

Returns:

  • (Array<String>)


8328
8329
8330
# File 'lib/google/apis/youtube_v3/classes.rb', line 8328

def tags
  @tags
end

#thumbnailsGoogle::Apis::YoutubeV3::ThumbnailDetails

Internal representation of thumbnails for a YouTube resource. Corresponds to the JSON property thumbnails



8333
8334
8335
# File 'lib/google/apis/youtube_v3/classes.rb', line 8333

def thumbnails
  @thumbnails
end

#titleString

The video's title. @mutable youtube.videos.insert youtube.videos.update Corresponds to the JSON property title

Returns:

  • (String)


8338
8339
8340
# File 'lib/google/apis/youtube_v3/classes.rb', line 8338

def title
  @title
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



8345
8346
8347
8348
8349
8350
8351
8352
8353
8354
8355
8356
8357
8358
# File 'lib/google/apis/youtube_v3/classes.rb', line 8345

def update!(**args)
  @category_id = args[:category_id] if args.key?(:category_id)
  @channel_id = args[:channel_id] if args.key?(:channel_id)
  @channel_title = args[:channel_title] if args.key?(:channel_title)
  @default_audio_language = args[:default_audio_language] if args.key?(:default_audio_language)
  @default_language = args[:default_language] if args.key?(:default_language)
  @description = args[:description] if args.key?(:description)
  @live_broadcast_content = args[:live_broadcast_content] if args.key?(:live_broadcast_content)
  @localized = args[:localized] if args.key?(:localized)
  @published_at = args[:published_at] if args.key?(:published_at)
  @tags = args[:tags] if args.key?(:tags)
  @thumbnails = args[:thumbnails] if args.key?(:thumbnails)
  @title = args[:title] if args.key?(:title)
end