Class: Yt::Models::AssetSnippet

Inherits:
Base
  • Object
show all
Defined in:
lib/yt/models/asset_snippet.rb

Overview

Provides methods to interact with YouTube ContentID assetSnippets.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Associations::HasReports

#has_report

Methods included from Associations::HasViewerPercentages

#has_viewer_percentages

Methods included from Associations::HasOne

#has_one

Methods included from Associations::HasMany

#has_many

Methods included from Associations::HasAuthentication

#has_authentication

Constructor Details

#initialize(options = {}) ⇒ AssetSnippet

Returns a new instance of AssetSnippet.



10
11
12
13
# File 'lib/yt/models/asset_snippet.rb', line 10

def initialize(options = {})
  @data = options.fetch(:data, {})
  @auth = options[:auth]
end

Instance Attribute Details

#authObject (readonly)

Returns the value of attribute auth.



8
9
10
# File 'lib/yt/models/asset_snippet.rb', line 8

def auth
  @auth
end

Instance Method Details

#custom_idString

Returns the Custom ID assigned by the content owner to this asset.

Returns:

  • (String)

    the Custom ID assigned by the content owner to this asset.



34
# File 'lib/yt/models/asset_snippet.rb', line 34

has_attribute :custom_id

#idString

Returns the ID that YouTube assigns and uses to uniquely identify the asset.

Returns:

  • (String)

    the ID that YouTube assigns and uses to uniquely identify the asset.



17
# File 'lib/yt/models/asset_snippet.rb', line 17

has_attribute :id

#isrcString

Returns the ISRC (International Standard Recording Code) for this asset.

Returns:

  • (String)

    the ISRC (International Standard Recording Code) for this asset.



38
# File 'lib/yt/models/asset_snippet.rb', line 38

has_attribute :isrc

#iswcString

Returns the ISWC (International Standard Musical Work Code) for this asset.

Returns:

  • (String)

    the ISWC (International Standard Musical Work Code) for this asset.



42
# File 'lib/yt/models/asset_snippet.rb', line 42

has_attribute :iswc

#titleString

Returns the title of this asset.

Returns:

  • (String)

    the title of this asset.



30
# File 'lib/yt/models/asset_snippet.rb', line 30

has_attribute :title

#typeString

Returns the asset’s type. This value determines the metadata fields that you can set for the asset. In addition, certain API functions may only be supported for specific types of assets. For example, composition assets may have more complex ownership data than other types of assets. Valid values for this property are: art_track_video, composition, episode, general, movie, music_video, season, show, sound_recording, video_game, and web.

Returns:

  • (String)

    the asset’s type. This value determines the metadata fields that you can set for the asset. In addition, certain API functions may only be supported for specific types of assets. For example, composition assets may have more complex ownership data than other types of assets. Valid values for this property are: art_track_video, composition, episode, general, movie, music_video, season, show, sound_recording, video_game, and web.



27
# File 'lib/yt/models/asset_snippet.rb', line 27

has_attribute :type