Class: Moceansdk::Modules::Voice::Mc

Inherits:
Object
  • Object
show all
Defined in:
lib/moceansdk/modules/voice/mc.rb

Class Method Summary collapse

Class Method Details

.collect(event_url = nil) ⇒ Object



36
37
38
39
40
41
42
43
44
# File 'lib/moceansdk/modules/voice/mc.rb', line 36

def self.collect(event_url = nil)
  ins = McObject::Collect.new

  unless event_url.nil?
    ins.event_url = event_url
  end

  ins
end

.dial(to = nil) ⇒ Object



26
27
28
29
30
31
32
33
34
# File 'lib/moceansdk/modules/voice/mc.rb', line 26

def self.dial(to = nil)
  ins = McObject::Dial.new

  unless to.nil?
    ins.to = to
  end

  ins
end

.play(file = nil) ⇒ Object



16
17
18
19
20
21
22
23
24
# File 'lib/moceansdk/modules/voice/mc.rb', line 16

def self.play(file = nil)
  ins = McObject::Play.new

  unless file.nil?
    ins.files = file
  end

  ins
end

.recordObject



56
57
58
# File 'lib/moceansdk/modules/voice/mc.rb', line 56

def self.record
  McObject::Record.new
end

.say(text = nil) ⇒ Object



6
7
8
9
10
11
12
13
14
# File 'lib/moceansdk/modules/voice/mc.rb', line 6

def self.say(text = nil)
  ins = McObject::Say.new

  unless text.nil?
    ins.text = text
  end

  ins
end

.sleep(duration = nil) ⇒ Object



46
47
48
49
50
51
52
53
54
# File 'lib/moceansdk/modules/voice/mc.rb', line 46

def self.sleep(duration = nil)
  ins = McObject::Sleep.new

  unless duration.nil?
    ins.duration = duration
  end

  ins
end