public interface Event
Core.publish(org.linphone.core.Address, java.lang.String, int, org.linphone.core.Content)
See also: 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.
|
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.
|
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 |
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.
|
int |
updatePublish(Content body)
Update (refresh) a publish.
|
int |
updateSubscribe(@Nullable Content body)
Update (refresh) an outgoing subscription, changing the body.
|
Core getCore()
ErrorInfo getErrorInfo()
Address getFrom()
java.lang.String getName()
PublishState getPublishState()
Reason getReason()
Address getRemoteContact()
Address getResource()
SubscriptionDir getSubscriptionDir()
SubscriptionState getSubscriptionState()
int acceptSubscription()
void addCustomHeader(java.lang.String name, java.lang.String value)
value
- the header's value.int denySubscription(Reason reason)
java.lang.String getCustomHeader(java.lang.String name)
name
- header's nameint notify(Content body)
body
- an optional body containing the actual notification data.void pausePublish()
ProxyConfig.refreshRegister()
.int refreshPublish()
int refreshSubscribe()
int sendPublish(Content body)
Core.createPublish(org.linphone.core.Address, java.lang.String, int)
.body
- the new data to be publishedint sendSubscribe(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, unless the
application explicitely took a reference on the object with linphone_event_ref.int updatePublish(Content body)
body
- the new data to be publishedint updateSubscribe(@Nullable @Nullable Content body)
body
- an optional body to include in the subscription update, may be
null.void 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()