Class: FSR::App::Say

Inherits:
Application show all
Defined in:
lib/fsr/app/say.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Application

#app_name, #raw, #sendmsg, #to_s

Constructor Details

#initialize(message, opts = {}) ⇒ Say

Returns a new instance of Say.



9
10
11
12
13
14
15
16
# File 'lib/fsr/app/say.rb', line 9

def initialize(message, opts = {})
  # wav file you wish to play, full path
  @message = message
  @language = opts[:language] || "en"
  @data_type = opts[:data_type] || "number"
  @say_method = opts[:say_method] || "pronounced"
  @gender = opts[:gender] || "feminine"
end

Instance Attribute Details

#messageObject (readonly)



7
8
9
# File 'lib/fsr/app/say.rb', line 7

def message
  @message
end

Instance Method Details

#argumentsObject



18
19
20
# File 'lib/fsr/app/say.rb', line 18

def arguments
  [@language, @data_type, @say_method, @gender, @message]
end