Class: Google::Apis::AddressvalidationV1::GoogleMapsAddressvalidationV1ComponentName

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

Overview

A wrapper for the name of the component.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleMapsAddressvalidationV1ComponentName

Returns a new instance of GoogleMapsAddressvalidationV1ComponentName.



279
280
281
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 279

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

Instance Attribute Details

#language_codeString

The BCP-47 language code. This will not be present if the component name is not associated with a language, such as a street number. Corresponds to the JSON property languageCode

Returns:

  • (String)


271
272
273
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 271

def language_code
  @language_code
end

#textString

The name text. For example, "5th Avenue" for a street name or "1253" for a street number. Corresponds to the JSON property text

Returns:

  • (String)


277
278
279
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 277

def text
  @text
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



284
285
286
287
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 284

def update!(**args)
  @language_code = args[:language_code] if args.key?(:language_code)
  @text = args[:text] if args.key?(:text)
end