Class: Google::Apis::AuthorizedbuyersmarketplaceV1alpha::AdSize

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

Overview

Represents size of a single ad slot, or a creative.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ AdSize

Returns a new instance of AdSize.



140
141
142
# File 'lib/google/apis/authorizedbuyersmarketplace_v1alpha/classes.rb', line 140

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

Instance Attribute Details

#heightFixnum

The height of the ad slot in pixels. This field will be present only when size type is PIXEL. Corresponds to the JSON property height

Returns:

  • (Fixnum)


127
128
129
# File 'lib/google/apis/authorizedbuyersmarketplace_v1alpha/classes.rb', line 127

def height
  @height
end

#typeString

The type of the ad slot size. Corresponds to the JSON property type

Returns:

  • (String)


132
133
134
# File 'lib/google/apis/authorizedbuyersmarketplace_v1alpha/classes.rb', line 132

def type
  @type
end

#widthFixnum

The width of the ad slot in pixels. This field will be present only when size type is PIXEL. Corresponds to the JSON property width

Returns:

  • (Fixnum)


138
139
140
# File 'lib/google/apis/authorizedbuyersmarketplace_v1alpha/classes.rb', line 138

def width
  @width
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



145
146
147
148
149
# File 'lib/google/apis/authorizedbuyersmarketplace_v1alpha/classes.rb', line 145

def update!(**args)
  @height = args[:height] if args.key?(:height)
  @type = args[:type] if args.key?(:type)
  @width = args[:width] if args.key?(:width)
end