Class: Google::Apis::TranslateV3::InputConfig

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

Overview

Input configuration for BatchTranslateText request.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ InputConfig

Returns a new instance of InputConfig.



365
366
367
# File 'generated/google/apis/translate_v3/classes.rb', line 365

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

Instance Attribute Details

#gcs_sourceGoogle::Apis::TranslateV3::GcsSource

The Google Cloud Storage location for the input content. Corresponds to the JSON property gcsSource



355
356
357
# File 'generated/google/apis/translate_v3/classes.rb', line 355

def gcs_source
  @gcs_source
end

#mime_typeString

Optional. Can be "text/plain" or "text/html". For .tsv, "text/html" is used if mime_type is missing. For .html, this field must be "text/html" or empty. For .txt, this field must be "text/plain" or empty. Corresponds to the JSON property mimeType

Returns:

  • (String)


363
364
365
# File 'generated/google/apis/translate_v3/classes.rb', line 363

def mime_type
  @mime_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



370
371
372
373
# File 'generated/google/apis/translate_v3/classes.rb', line 370

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