public interface OriginateCallback
Contract:
onDialing(AsteriskChannel)
is called exactly once iif originate did not fail.
It is called immediately after the channel has been created and before it is ringing.
In case of a failure onFailure(LiveException)
is the only method that is called
and it is called exactly once.
Otherwise one of onSuccess(AsteriskChannel)
onBusy(AsteriskChannel)
or
onNoAnswer(AsteriskChannel)
is called exactly once.
AsteriskServer.originateToApplicationAsync(String, String, String, long, OriginateCallback)
,
AsteriskServer.originateToApplicationAsync(String, String, String, long, CallerId, java.util.Map, OriginateCallback)
,
AsteriskServer.originateToExtensionAsync(String, String, String, int, long, OriginateCallback)
,
AsteriskServer.originateToExtensionAsync(String, String, String, int, long, CallerId, java.util.Map, OriginateCallback)
Modifier and Type | Method and Description |
---|---|
void |
onBusy(AsteriskChannel channel)
Called if the originate was unsuccessful because the called party was
busy.
|
void |
onDialing(AsteriskChannel channel)
Called when the channel has been created and before it starts ringing.
|
void |
onFailure(LiveException cause)
Called if the originate failed for example due to an invalid channel name
or an originate to an unregistered SIP or IAX peer.
|
void |
onNoAnswer(AsteriskChannel channel)
Called if the originate was unsuccessful because the called party did not
answer the call.
|
void |
onSuccess(AsteriskChannel channel)
Called if the originate was successful and the called party answered the
call.
|
void onDialing(AsteriskChannel channel)
channel
- the channel created.void onSuccess(AsteriskChannel channel)
channel
- the channel created.void onNoAnswer(AsteriskChannel channel)
channel
- the channel created.void onBusy(AsteriskChannel channel)
channel
- the channel created.void onFailure(LiveException cause)
cause
- the exception that caused the failure.Copyright © 2004–2022. All rights reserved.