Class: Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentTranslation
- Inherits:
-
Object
- Object
- Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentTranslation
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/documentai_v1beta3/classes.rb,
lib/google/apis/documentai_v1beta3/representations.rb,
lib/google/apis/documentai_v1beta3/representations.rb
Overview
A translation of the text segment.
Instance Attribute Summary collapse
-
#language_code ⇒ String
The BCP-47 language code, such as "en-US" or "sr-Latn".
-
#provenance ⇒ Array<Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentProvenance>
The history of this annotation.
-
#text_anchor ⇒ Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentTextAnchor
Text reference indexing into the Document.text.
-
#translated_text ⇒ String
Text translated into the target language.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudDocumentaiV1beta2DocumentTranslation
constructor
A new instance of GoogleCloudDocumentaiV1beta2DocumentTranslation.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudDocumentaiV1beta2DocumentTranslation
Returns a new instance of GoogleCloudDocumentaiV1beta2DocumentTranslation.
4084 4085 4086 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4084 def initialize(**args) update!(**args) end |
Instance Attribute Details
#language_code ⇒ String
The 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
4067 4068 4069 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4067 def language_code @language_code end |
#provenance ⇒ Array<Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentProvenance>
The history of this annotation.
Corresponds to the JSON property provenance
4072 4073 4074 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4072 def provenance @provenance end |
#text_anchor ⇒ Google::Apis::DocumentaiV1beta3::GoogleCloudDocumentaiV1beta2DocumentTextAnchor
Text reference indexing into the Document.text.
Corresponds to the JSON property textAnchor
4077 4078 4079 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4077 def text_anchor @text_anchor end |
#translated_text ⇒ String
Text translated into the target language.
Corresponds to the JSON property translatedText
4082 4083 4084 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4082 def translated_text @translated_text end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
4089 4090 4091 4092 4093 4094 |
# File 'lib/google/apis/documentai_v1beta3/classes.rb', line 4089 def update!(**args) @language_code = args[:language_code] if args.key?(:language_code) @provenance = args[:provenance] if args.key?(:provenance) @text_anchor = args[:text_anchor] if args.key?(:text_anchor) @translated_text = args[:translated_text] if args.key?(:translated_text) end |