Object representing an event state, which is subcribed or published.
- Source:
Members
-
<readonly> core :external:LinphoneCore
-
Returns back pointer to the LinphoneCore that created this LinphoneEvent
Type:
- Source:
-
<readonly> errorInfo :external:LinphoneErrorInfo
-
Get full details about an error occured.
Type:
- Source:
-
<readonly> from :external:LinphoneAddress
-
Get the "from" address of the subscription.
Type:
- Source:
-
<readonly> name :string
-
Get the name of the event as specified in the event package RFC.
Type:
- string
- Source:
-
<readonly> publishState :linphone.PublishState
-
Get publish state. If the event object was not created by a publish mechanism,
Type:
- Source:
-
<readonly> reason :linphone.Reason
-
Return reason code (in case of error state reached).
Type:
- Source:
-
<readonly> resource :external:LinphoneAddress
-
Get the resource address of the subscription or publish.
Type:
- Source:
-
<readonly> subscriptionDir :linphone.SubscriptionDir
-
Get subscription direction. If the object wasn't created by a subscription mechanism,
Type:
- Source:
-
<readonly> subscriptionState :linphone.SubscriptionState
-
Get subscription state. If the event object was not created by a subscription mechanism,
Type:
- Source:
Methods
-
acceptSubscription() → {number}
-
Accept an incoming subcription.
- Source:
Returns:
- Type
- number
-
addCustomHeader(name, value) → {void}
-
Add a custom header to an outgoing susbscription or publish.
Parameters:
Name Type Description name
string header's name value
string the header's value. - Source:
Returns:
- Type
- void
-
denySubscription(reason) → {number}
-
Deny an incoming subscription with given reason.
Parameters:
Name Type Description reason
linphone.Reason - - Source:
Returns:
- Type
- number
-
getCustomHeader(name) → {string}
-
Obtain the value of a given header for an incoming subscription.
Parameters:
Name Type Description name
string header's name - Source:
Returns:
- Type
- string
-
notify(body) → {number}
-
Send a notification.
Parameters:
Name Type Description body
external:LinphoneContent an optional body containing the actual notification data. - Source:
Returns:
- Type
- number
-
sendPublish(body) → {number}
-
Send a publish created by
Parameters:
Name Type Description body
external:LinphoneContent the new data to be published - Source:
Returns:
- Type
- number
-
sendSubscribe(body) → {number}
-
Send a subscription previously created by
Parameters:
Name Type Description body
external:LinphoneContent optional content to attach with the subscription. - Source:
Returns:
- Type
- number
-
terminate() → {void}
-
Terminate an incoming or outgoing subscription that was previously acccepted, or a previous publication. This function does not unref the object. The core will unref() if it does not need this object anymore.
- Source:
Returns:
- Type
- void
-
updatePublish(body) → {number}
-
Update (refresh) a publish.
Parameters:
Name Type Description body
external:LinphoneContent the new data to be published - Source:
Returns:
- Type
- number
-
updateSubscribe(body) → {number}
-
Update (refresh) an outgoing subscription.
Parameters:
Name Type Description body
external:LinphoneContent an optional body to include in the subscription update, may be NULL. - Source:
Returns:
- Type
- number