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

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.



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

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.



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

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.



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

has_attribute :iswc

#titleString

Returns the title of this asset.

Returns:

  • (String)

    the title of this asset.



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

has_attribute :title

#typeString

Returns the asset’s type.

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. Possible values are: ‘art_track_video’, ‘composition’, ‘episode’, ‘general’, ‘movie’, ‘music_video’, ‘season’, ‘show’, ‘sound_recording’, ‘video_game’, ‘web’.



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

has_attribute :type