Class: Google::Apis::AdsensehostV4_1::AdUnit

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

Defined Under Namespace

Classes: ContentAdsSettings, MobileContentAdsSettings

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) ⇒ AdUnit

Returns a new instance of AdUnit.



364
365
366
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 364

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

Instance Attribute Details

#codeString

Identity code of this ad unit, not necessarily unique across ad clients. Corresponds to the JSON property code

Returns:

  • (String)


319
320
321
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 319

def code
  @code
end

#content_ads_settingsGoogle::Apis::AdsensehostV4_1::AdUnit::ContentAdsSettings

Settings specific to content ads (AFC) and highend mobile content ads (AFMC - deprecated). Corresponds to the JSON property contentAdsSettings



325
326
327
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 325

def content_ads_settings
  @content_ads_settings
end

#custom_styleGoogle::Apis::AdsensehostV4_1::AdStyle

Custom style information specific to this ad unit. Corresponds to the JSON property customStyle



330
331
332
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 330

def custom_style
  @custom_style
end

#idString

Unique identifier of this ad unit. This should be considered an opaque identifier; it is not safe to rely on it being in any particular format. Corresponds to the JSON property id

Returns:

  • (String)


336
337
338
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 336

def id
  @id
end

#kindString

Kind of resource this is, in this case adsensehost#adUnit. Corresponds to the JSON property kind

Returns:

  • (String)


341
342
343
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 341

def kind
  @kind
end

#mobile_content_ads_settingsGoogle::Apis::AdsensehostV4_1::AdUnit::MobileContentAdsSettings

Settings specific to WAP mobile content ads (AFMC - deprecated). Corresponds to the JSON property mobileContentAdsSettings



346
347
348
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 346

def mobile_content_ads_settings
  @mobile_content_ads_settings
end

#nameString

Name of this ad unit. Corresponds to the JSON property name

Returns:

  • (String)


351
352
353
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 351

def name
  @name
end

#statusString

Status of this ad unit. Possible values are: NEW: Indicates that the ad unit was created within the last seven days and does not yet have any activity associated with it. ACTIVE: Indicates that there has been activity on this ad unit in the last seven days. INACTIVE: Indicates that there has been no activity on this ad unit in the last seven days. Corresponds to the JSON property status

Returns:

  • (String)


362
363
364
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 362

def status
  @status
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



369
370
371
372
373
374
375
376
377
378
# File 'generated/google/apis/adsensehost_v4_1/classes.rb', line 369

def update!(**args)
  @code = args[:code] if args.key?(:code)
  @content_ads_settings = args[:content_ads_settings] if args.key?(:content_ads_settings)
  @custom_style = args[:custom_style] if args.key?(:custom_style)
  @id = args[:id] if args.key?(:id)
  @kind = args[:kind] if args.key?(:kind)
  @mobile_content_ads_settings = args[:mobile_content_ads_settings] if args.key?(:mobile_content_ads_settings)
  @name = args[:name] if args.key?(:name)
  @status = args[:status] if args.key?(:status)
end