Speedify SDK for Android 15.5.0
Loading...
Searching...
No Matches
IForegroundNotificationReceiver Interface Reference

Foreground Service notification Interface. More...

Inheritance diagram for IForegroundNotificationReceiver:
IForegroundServiceReceiver ISpeedifyHandler SpeedifyHandler

Classes

class  ServiceData
 Common status data used in default foreground notification. More...
 

Public Member Functions

void UpdateForegroundNotification (@NonNull Service service, @NonNull ServiceData serviceData)
 Callback to show a notification of the service state.
 
void HideForegroundNotification (@NonNull Service service)
 Callback when vpn service task is removed.
 

Detailed Description

Foreground Service notification Interface.

All calls happen from the background :vpnservice process. All calls are sent from background threads.

Since
14.7

Member Function Documentation

◆ HideForegroundNotification()

void HideForegroundNotification ( @NonNull Service service)

Callback when vpn service task is removed.

If overriding UpdateForegroundNotification, use this to hide your notification. Called from secondary (:vpnservice) process.

Parameters
serviceReference to the vpn service
Since
5.6

Implemented in SpeedifyHandler.

◆ UpdateForegroundNotification()

void UpdateForegroundNotification ( @NonNull Service service,
@NonNull ServiceData serviceData )

Callback to show a notification of the service state.

A default implementation is provided. If overriding, it is required on Oreo and higher that you call service.startForeground so that Android does not automatically stop the service after a few seconds. Prior to Oreo it is still recommended to use service.startForeground so that Android is less likely to destroy the service in low memory situations. Called from secondary (:vpnservice) process.

Parameters
serviceReference to the vpn service
serviceDataData to use in the notification
Since
14.0

The documentation for this interface was generated from the following file: