Relay.Calling.DetectResult
This object returned from one of synchronous detect methods that represents the final result of a detector.
Methods
getEvent
Returns the last Relay Event arrived for this operation.
Parameters
None
Returns
Relay.Event - Last Relay Event.
Examples
Detect digits and grab the result when it’s completed.
getResult
Returns the result of the detector. It could be the digits or the type (machine or human) detected.
Parameters
None
Returns
string - Detector result.
Examples
Detect DTMF and print out the result.
getType
Returns the type of detector.
Parameters
None
Returns
string - Detector type: digit, machine or fax.
Examples
Check the type of a detector.
isSuccessful
Return true if detector succeeded, false otherwise.
Parameters
None
Returns
Boolean - True/False accordingly to the state.
Examples
Start detecting a fax, then check if a fax has been detected.