Class: Google::Apis::YoutubePartnerV1::AdBreak

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ AdBreak

Returns a new instance of AdBreak.


46
47
48
# File 'generated/google/apis/youtube_partner_v1/classes.rb', line 46

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

Instance Attribute Details

#midroll_secondsFixnum

The time of the ad break specified as the number of seconds after the start of the video when the break occurs. Corresponds to the JSON property midrollSeconds

Returns:

  • (Fixnum)

33
34
35
# File 'generated/google/apis/youtube_partner_v1/classes.rb', line 33

def midroll_seconds
  @midroll_seconds
end

#positionString

The point at which the break occurs during the video playback. Corresponds to the JSON property position

Returns:

  • (String)

38
39
40
# File 'generated/google/apis/youtube_partner_v1/classes.rb', line 38

def position
  @position
end

#slotArray<Google::Apis::YoutubePartnerV1::AdSlot>

A list of ad slots that occur in an ad break. Ad slots let you specify the number of ads that should run in each break. Corresponds to the JSON property slot


44
45
46
# File 'generated/google/apis/youtube_partner_v1/classes.rb', line 44

def slot
  @slot
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object


51
52
53
54
55
# File 'generated/google/apis/youtube_partner_v1/classes.rb', line 51

def update!(**args)
  @midroll_seconds = args[:midroll_seconds] if args.key?(:midroll_seconds)
  @position = args[:position] if args.key?(:position)
  @slot = args[:slot] if args.key?(:slot)
end