public interface Event
Core.publish(org.linphone.core.Address, java.lang.String, int, org.linphone.core.Content)
Core.subscribe(org.linphone.core.Address, java.lang.String, int, org.linphone.core.Content)
Modifier and Type | Method and Description |
---|---|
int |
acceptSubscription()
Accept an incoming subcription.
|
void |
addCustomHeader(java.lang.String name,
java.lang.String value)
Add a custom header to an outgoing susbscription or publish.
|
void |
addListener(EventListener listener) |
int |
denySubscription(Reason reason)
Deny an incoming subscription with given reason.
|
Core |
getCore()
|
java.lang.String |
getCustomHeader(java.lang.String name)
Obtain the value of a given header for an incoming subscription.
|
ErrorInfo |
getErrorInfo()
Get full details about an error occured.
|
Address |
getFrom()
Get the "from" address of the subscription.
|
java.lang.String |
getName()
Get the name of the event as specified in the event package RFC.
|
long |
getNativePointer()
Gets the native pointer used by this class to make native method calls.
|
PublishState |
getPublishState()
Get publish state.
|
Reason |
getReason()
Return reason code (in case of error state reached).
|
Address |
getRemoteContact()
Get the "contact" address of the subscription.
|
Address |
getResource()
Get the resource address of the subscription or publish.
|
SubscriptionDir |
getSubscriptionDir()
Get subscription direction.
|
SubscriptionState |
getSubscriptionState()
Get subscription state.
|
Address |
getTo()
Get the "to" address of the subscription.
|
java.lang.Object |
getUserData()
Gets the object stored in this object user's data
|
int |
notify(Content body)
Send a notification.
|
void |
pausePublish()
Prevent an event from refreshing its publish.
|
int |
refreshPublish()
Refresh an outgoing publish keeping the same body.
|
int |
refreshSubscribe()
Refresh an outgoing subscription keeping the same body.
|
void |
removeCustomHeader(java.lang.String name)
Remove custom header to an outgoing susbscription or publish.
|
void |
removeListener(EventListener listener) |
int |
sendPublish(Content body)
Send a publish created by
Core.createPublish(org.linphone.core.Address, java.lang.String, int) . |
int |
sendSubscribe(Content body)
Send a subscription previously created by
Core.createSubscribe(org.linphone.core.Address, org.linphone.core.ProxyConfig, java.lang.String, int) . |
void |
setListener(EventListener listener) |
void |
setUserData(java.lang.Object data)
Sets the object to store in this object user's data
|
void |
terminate()
Terminate an incoming or outgoing subscription that was previously acccepted,
or a previous publication. |
java.lang.String |
toString() |
int |
updatePublish(Content body)
Update (refresh) a publish.
|
int |
updateSubscribe(Content body)
Update (refresh) an outgoing subscription, changing the body.
|
@NonNull ErrorInfo getErrorInfo()
ErrorInfo
object. @NonNull Address getFrom()
Address
. @NonNull java.lang.String getName()
PublishState getPublishState()
PublishState.None
PublishState
Reason getReason()
Reason
enum @NonNull Address getRemoteContact()
@NonNull Address getResource()
Address
. SubscriptionDir getSubscriptionDir()
SubscriptionDir.InvalidDir
SubscriptionDir
SubscriptionState getSubscriptionState()
SubscriptionState.None
SubscriptionState
int acceptSubscription()
void addCustomHeader(@NonNull java.lang.String name, @Nullable java.lang.String value)
name
- header's name value
- the header's value. int denySubscription(Reason reason)
@Nullable java.lang.String getCustomHeader(@NonNull java.lang.String name)
name
- header's name int notify(@Nullable Content body)
body
- an optional body containing the actual notification data. void pausePublish()
ProxyConfig.refreshRegister()
. int refreshPublish()
int refreshSubscribe()
void removeCustomHeader(@NonNull java.lang.String name)
name
- header's name int sendPublish(@NonNull Content body)
body
- the new data to be published int sendSubscribe(@Nullable Content body)
Core.createSubscribe(org.linphone.core.Address, org.linphone.core.ProxyConfig, java.lang.String, int)
. body
- optional content to attach with the subscription. void terminate()
Event
shall not be used anymore after this operation. int updatePublish(@NonNull Content body)
body
- the new data to be published @Nullable int updateSubscribe(@Nullable Content body)
body
- an optional body to include in the subscription update, may bevoid addListener(EventListener listener)
void removeListener(EventListener listener)
void setListener(EventListener listener)
void setUserData(java.lang.Object data)
data
- the object to storejava.lang.Object getUserData()
long getNativePointer()
java.lang.String toString()
toString
in class java.lang.Object