Class: Google::Apis::Searchads360V23::GoogleAdsSearchads360V23CommonFrequencyCapKey

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

Overview

A group of fields used as keys for a frequency cap. There can be no more than one frequency cap with the same key.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleAdsSearchads360V23CommonFrequencyCapKey

Returns a new instance of GoogleAdsSearchads360V23CommonFrequencyCapKey.



5194
5195
5196
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5194

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

Instance Attribute Details

#event_typeString

The type of event that the cap applies to (for example, impression). Corresponds to the JSON property eventType

Returns:

  • (String)


5176
5177
5178
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5176

def event_type
  @event_type
end

#levelString

The level on which the cap is to be applied (for example, ad group ad, ad group). The cap is applied to all the entities of this level. Corresponds to the JSON property level

Returns:

  • (String)


5182
5183
5184
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5182

def level
  @level
end

#time_lengthFixnum

Number of time units the cap lasts. Corresponds to the JSON property timeLength

Returns:

  • (Fixnum)


5187
5188
5189
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5187

def time_length
  @time_length
end

#time_unitString

Unit of time the cap is defined at (for example, day, week). Corresponds to the JSON property timeUnit

Returns:

  • (String)


5192
5193
5194
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5192

def time_unit
  @time_unit
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5199
5200
5201
5202
5203
5204
# File 'lib/google/apis/searchads360_v23/classes.rb', line 5199

def update!(**args)
  @event_type = args[:event_type] if args.key?(:event_type)
  @level = args[:level] if args.key?(:level)
  @time_length = args[:time_length] if args.key?(:time_length)
  @time_unit = args[:time_unit] if args.key?(:time_unit)
end