class Google::Apis::SpeechV1p1beta1::RecognitionAudio

Contains audio data in the encoding specified in the `RecognitionConfig`. Either `content` or `uri` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. See [content limits](cloud.google. com/speech-to-text/quotas#content).

Attributes

content[RW]

The audio data bytes encoded as specified in `RecognitionConfig`. Note: as with all bytes fields, proto buffers use a pure binary representation, whereas JSON representations use base64. Corresponds to the JSON property `content` NOTE: Values are automatically base64 encoded/decoded in the client library. @return [String]

uri[RW]

URI that points to a file that contains audio data bytes as specified in ` RecognitionConfig`. The file must not be compressed (for example, gzip). Currently, only Google Cloud Storage URIs are supported, which must be specified in the following format: `gs://bucket_name/object_name` (other URI formats return google.rpc.Code.INVALID_ARGUMENT). For more information, see [ Request URIs](cloud.google.com/storage/docs/reference-uris). Corresponds to the JSON property `uri` @return [String]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/speech_v1p1beta1/classes.rb, line 566
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/speech_v1p1beta1/classes.rb, line 571
def update!(**args)
  @content = args[:content] if args.key?(:content)
  @uri = args[:uri] if args.key?(:uri)
end