Class: Google::Apis::PlacesV1::GoogleTypeLocalizedText

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

Overview

Localized variant of a text in a particular language.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleTypeLocalizedText

Returns a new instance of GoogleTypeLocalizedText.



2560
2561
2562
# File 'lib/google/apis/places_v1/classes.rb', line 2560

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

Instance Attribute Details

#language_codeString

The text's BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/# Unicode_locale_identifier. Corresponds to the JSON property languageCode

Returns:

  • (String)


2553
2554
2555
# File 'lib/google/apis/places_v1/classes.rb', line 2553

def language_code
  @language_code
end

#textString

Localized string in the language corresponding to language_code below. Corresponds to the JSON property text

Returns:

  • (String)


2558
2559
2560
# File 'lib/google/apis/places_v1/classes.rb', line 2558

def text
  @text
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2565
2566
2567
2568
# File 'lib/google/apis/places_v1/classes.rb', line 2565

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