Class: Yt::Models::AdvertisingOptionsSet
- Inherits:
-
Base
- Object
- Base
- Yt::Models::AdvertisingOptionsSet
- Defined in:
- lib/yt/models/advertising_options_set.rb
Overview
Encapsulates advertising options of a video, such as the types of ads that can run during the video as well as the times when ads are allowed to run during the video.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ AdvertisingOptionsSet
constructor
A new instance of AdvertisingOptionsSet.
- #update(attributes = {}) ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ AdvertisingOptionsSet
Returns a new instance of AdvertisingOptionsSet.
10 11 12 13 14 |
# File 'lib/yt/models/advertising_options_set.rb', line 10 def initialize( = {}) @auth = [:auth] @video_id = [:video_id] @data = [:data] end |
Instance Method Details
#update(attributes = {}) ⇒ Object
16 17 18 19 20 |
# File 'lib/yt/models/advertising_options_set.rb', line 16 def update(attributes = {}) underscore_keys! attributes do_patch(body: attributes) {|data| @data = data} true end |