Class: Google::Apis::AuthorizedbuyersmarketplaceV1::AdSize

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb,
lib/google/apis/authorizedbuyersmarketplace_v1/representations.rb,
lib/google/apis/authorizedbuyersmarketplace_v1/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.



92
93
94
# File 'lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb', line 92

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)


79
80
81
# File 'lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb', line 79

def height
  @height
end

#typeString

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

Returns:

  • (String)


84
85
86
# File 'lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb', line 84

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)


90
91
92
# File 'lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb', line 90

def width
  @width
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



97
98
99
100
101
# File 'lib/google/apis/authorizedbuyersmarketplace_v1/classes.rb', line 97

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