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.



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

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)


268
269
270
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 268

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)


274
275
276
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 274

def text
  @text
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



281
282
283
284
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 281

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