Module: Adhearsion::CallController::Dial
- Included in:
- Adhearsion::CallController
- Defined in:
- lib/adhearsion/call_controller/dial.rb
Defined Under Namespace
Classes: Dial, DialStatus, JoinStatus, ParallelConfirmationDial
Instance Method Summary collapse
-
#dial(to, options = {}) ⇒ DialStatus
Dial one or more third parties and join one to this call.
-
#dial_and_confirm(to, options = {}) ⇒ Object
Dial one or more third parties and join one to this call after execution of a confirmation controller.
Instance Method Details
#dial(to[String], options = {}) ⇒ DialStatus #dial(to[Array], options = {}) ⇒ DialStatus #dial(to[Hash], options = {}) ⇒ DialStatus
Dial one or more third parties and join one to this call
60 61 62 63 64 65 66 67 68 69 |
# File 'lib/adhearsion/call_controller/dial.rb', line 60 def dial(to, = {}) dial = Dial.new to, , call dial.run(self) dial.await_completion dial.terminate_ringback dial.cleanup_calls dial.status ensure catching_standard_errors { dial.delete_logger if dial } end |
#dial_and_confirm(to, options = {}) ⇒ Object
Dial one or more third parties and join one to this call after execution of a confirmation controller. Confirmation will be attempted on all answered calls, and calls will be allowed to progress through confirmation in parallel. The first to complete confirmation will be joined to the A-leg, with the others being hung up.
77 78 79 80 81 82 83 84 85 86 |
# File 'lib/adhearsion/call_controller/dial.rb', line 77 def dial_and_confirm(to, = {}) dial = ParallelConfirmationDial.new to, , call dial.run(self) dial.await_completion dial.terminate_ringback dial.cleanup_calls dial.status ensure catching_standard_errors { dial.delete_logger if dial } end |