Sha256: 39c46898468f6011f3f05659910d536989a93e0d4ab3f8baa24769fcf937fc12
Contents?: true
Size: 920 Bytes
Versions: 5
Compression:
Stored size: 920 Bytes
Contents
# frozen_string_literal: true module AzureSTT module Parsers # # Parse a transcription from the call to the API to a Models::Transcription # class Transcription < Base protected # rubocop:disable Metrics/AbcSize # # Build a hash which can create a Models::Transcription # # @return [Hash] transcription's initializer parameters # def build_attributes { id: hash['self'].split('/').last, model: hash.dig('model', 'self'), links: hash['links'], properties: hash['properties'], last_action_date_time: Date.parse(hash['lastActionDateTime']), created_date_time: Date.parse(hash['createdDateTime']), status: hash['status'], locale: hash['locale'], display_name: hash['displayName'] } end # rubocop:enable Metrics/AbcSize end end end
Version data entries
5 entries across 5 versions & 1 rubygems