Class: Aws::TranscribeService::Waiters::VocabularyReady

Inherits:
Object
  • Object
show all
Defined in:
gems/aws-sdk-transcribeservice/lib/aws-sdk-transcribeservice/waiters.rb

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ VocabularyReady

Returns a new instance of VocabularyReady.

Parameters:

  • options (Hash)

Options Hash (options):

  • :client (required, Client)
  • :max_attempts (Integer) — default: 180
  • :delay (Integer) — default: 10
  • :before_attempt (Proc)
  • :before_wait (Proc)


354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
# File 'gems/aws-sdk-transcribeservice/lib/aws-sdk-transcribeservice/waiters.rb', line 354

def initialize(options)
  @client = options.fetch(:client)
  @waiter = Aws::Waiters::Waiter.new({
    max_attempts: 180,
    delay: 10,
    poller: Aws::Waiters::Poller.new(
      operation_name: :get_vocabulary,
      acceptors: [
        {
          "state" => "success",
          "matcher" => "path",
          "argument" => "vocabulary_state",
          "expected" => "READY"
        },
        {
          "state" => "failure",
          "matcher" => "path",
          "argument" => "vocabulary_state",
          "expected" => "FAILED"
        }
      ]
    )
  }.merge(options))
end

Instance Method Details

#wait(params = {}) ⇒ Types::GetVocabularyResponse

Returns a response object which responds to the following methods:

Parameters:

  • params (Hash) (defaults to: {})

    a customizable set of options

Options Hash (params):

  • :vocabulary_name (required, String)

    The name of the custom vocabulary you want information about. Custom vocabulary names are case sensitive.

Returns:



381
382
383
# File 'gems/aws-sdk-transcribeservice/lib/aws-sdk-transcribeservice/waiters.rb', line 381

def wait(params = {})
  @waiter.wait(client: @client, params: params)
end