Constructor
new module:caplin/sljsadapter/providers/StreamLinkNotificationService(providedStreamlinkNotificationAPIopt)
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
providedStreamlinkNotificationAPI |
caplin.streamlink.alerts.NotificationService |
<optional> |
new caplin.streamlink.alerts.NotificationService() | provide a fake streamlink API for testing |
Methods
-
dismiss(dismissedNotification, erroropt, successopt)
-
This method is meant to be invoked by UI components wishing to dismiss a notification. It uses the streamlink API to dismiss the given notification.
Parameters:
Name Type Attributes Description dismissedNotification
caplin/alerts/Notification The notification to be dismissed. error
function <optional>
Callback to be invoked on streamlink contrib error. success
function <optional>
Callback to be invoked on successful request. Throws:
-
If dismissedNotification is not a Notification or if error and success are not functions.
- Type
- br/Errors.InvalidParametersError
-
-
dispose()
-
Disposes of any listeners and resources that were used by the service.