Class: Google::Apis::TranslateV2::LanguagesResource
- Inherits:
-
Object
- Object
- Google::Apis::TranslateV2::LanguagesResource
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/translate_v2/classes.rb,
generated/google/apis/translate_v2/representations.rb,
generated/google/apis/translate_v2/representations.rb
Instance Attribute Summary collapse
-
#language ⇒ String
Supported language code, generally consisting of its ISO 639-1 identifier.
-
#name ⇒ String
Human readable name of the language localized to the target language.
Instance Method Summary collapse
-
#initialize(**args) ⇒ LanguagesResource
constructor
A new instance of LanguagesResource.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ LanguagesResource
Returns a new instance of LanguagesResource
154 155 156 |
# File 'generated/google/apis/translate_v2/classes.rb', line 154 def initialize(**args) update!(**args) end |
Instance Attribute Details
#language ⇒ String
Supported language code, generally consisting of its ISO 639-1
identifier. (E.g. 'en', 'ja'). In certain cases, BCP-47 codes including
language + region identifiers are returned (e.g. 'zh-TW' and 'zh-CH')
Corresponds to the JSON property language
147 148 149 |
# File 'generated/google/apis/translate_v2/classes.rb', line 147 def language @language end |
#name ⇒ String
Human readable name of the language localized to the target language.
Corresponds to the JSON property name
152 153 154 |
# File 'generated/google/apis/translate_v2/classes.rb', line 152 def name @name end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
159 160 161 162 |
# File 'generated/google/apis/translate_v2/classes.rb', line 159 def update!(**args) @language = args[:language] if args.key?(:language) @name = args[:name] if args.key?(:name) end |