Class: Google::Apis::TranslateV3::GlossaryTerm

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

Overview

Represents a single glossary term

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GlossaryTerm

Returns a new instance of GlossaryTerm.



605
606
607
# File 'lib/google/apis/translate_v3/classes.rb', line 605

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

Instance Attribute Details

#language_codeString

The language for this glossary term. Corresponds to the JSON property languageCode

Returns:

  • (String)


598
599
600
# File 'lib/google/apis/translate_v3/classes.rb', line 598

def language_code
  @language_code
end

#textString

The text for the glossary term. Corresponds to the JSON property text

Returns:

  • (String)


603
604
605
# File 'lib/google/apis/translate_v3/classes.rb', line 603

def text
  @text
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



610
611
612
613
# File 'lib/google/apis/translate_v3/classes.rb', line 610

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