Class: Google::Apis::DialogflowV2::GoogleCloudDialogflowV2CustomPronunciationParams

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

Overview

Pronunciation customization for a phrase.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDialogflowV2CustomPronunciationParams

Returns a new instance of GoogleCloudDialogflowV2CustomPronunciationParams.



10364
10365
10366
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 10364

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

Instance Attribute Details

#phonetic_encodingString

The phonetic encoding of the phrase. Corresponds to the JSON property phoneticEncoding

Returns:

  • (String)


10350
10351
10352
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 10350

def phonetic_encoding
  @phonetic_encoding
end

#phraseString

The phrase to which the customization is applied. The phrase can be multiple words, such as proper nouns, but shouldn't span the length of the sentence. Corresponds to the JSON property phrase

Returns:

  • (String)


10356
10357
10358
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 10356

def phrase
  @phrase
end

#pronunciationString

The pronunciation of the phrase. This must be in the phonetic encoding specified above. Corresponds to the JSON property pronunciation

Returns:

  • (String)


10362
10363
10364
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 10362

def pronunciation
  @pronunciation
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



10369
10370
10371
10372
10373
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 10369

def update!(**args)
  @phonetic_encoding = args[:phonetic_encoding] if args.key?(:phonetic_encoding)
  @phrase = args[:phrase] if args.key?(:phrase)
  @pronunciation = args[:pronunciation] if args.key?(:pronunciation)
end