![]() |
Speedify SDK for Android
15.3.0
|
SDK State Update Reciever Interface.
These calls only happen on the main process by default. All calls are sent from background threads. As of 11.1, EnableSDKHandlerFromBackground enables these to also be delivered to the background process.
Public Member Functions | |
default void | OnLoginError (ErrorType errorType, @Nullable String message) |
Error when logging in. More... | |
default void | OnActivationCode (ErrorType errorType, @Nullable String message, @NonNull String activationCode, @NonNull String activationUrl) |
Activation code result. More... | |
default void | OnConnectError (ErrorType errorType, @Nullable String message) |
Error when connecting to a server. More... | |
default void | OnState (State state) |
State update received. More... | |
default void | OnConnectedServer (@Nullable ServerInformation serverInfo) |
Connected update received. More... | |
default void | OnAdaptersList (@NonNull List< AdapterData > adapters) |
Network adapters list update received. More... | |
default void | OnDirectory (@NonNull List< ServerInformation > servers) |
Directory update received This list can be refreshed with refreshDirectory. More... | |
default void | OnConnectionStats (@NonNull ConnectionStatsGroup tunnelStats) |
Latest tunnel stats update. More... | |
default void | OnConnectionStats (@NonNull List< ConnectionStatsGroup > tunnelStats) |
Historic tunnel stats update. More... | |
default void | OnSessionStats (@NonNull SessionStatPeriods stats) |
Session stats update. More... | |
default void | OnStreamingStats (StreamingStats stats) |
Streaming stats update. More... | |
default void | OnNewAdapter (@NonNull String adapterID, NetworkType type) |
Notification for the first time seeing a new adapter. More... | |
default void | OnAdapterOverlimit (@NonNull String adapterID, NetworkType type, @NonNull AdapterUsageData usageData) |
Notification when an adapter is near its daily or monthly data usage limit. More... | |
default void | OnSettings (@NonNull Settings settings) |
Notification on settings change. More... | |
default void | OnAccountingData (@NonNull AccountingData accounting) |
Accounting data update This can be refreshed with refreshAccounting. More... | |
default void | OnPrivacySettings (@NonNull PrivacySettings privacy) |
Privacy settings update This can be refreshed with refreshPrivacy. More... | |
default void | OnDirectorySettings (@NonNull DirectorySettings directorySettings) |
Directory settings update This can be refreshed with refreshDirectorySettings. More... | |
default void | OnAccountCheckResult (ErrorType errorType, @Nullable String errorMessage, boolean accountExists) |
Account check result. More... | |
default void | OnAccountCreateResult (ErrorType errorType, @Nullable String errorMessage) |
Account create result. More... | |
default void | OnPasswordChangeResult (ErrorType errorType, @Nullable String errorMessage) |
Password change result. More... | |
default void | OnTorrentDetection (boolean willDisconnect) |
A torrent use was detected. More... | |
default void | OnNonVPNApplications (@NonNull List< String > nonVpnApps) |
List of apps configured to go around the VPN. More... | |
default void | OnSettingError (@NonNull String settingAction, ErrorType errorType, @Nullable String message) |
Called in response to an error changing a setting. More... | |
default void | OnLocalVendorSettings (@Nullable JSONObject settings) |
Local vendor settings update. More... | |
default void | OnRemoteVendorSettings (@Nullable JSONObject settings) |
Remote vendor settings update. More... | |
default void | OnVendorUserData (@Nullable String userData) |
Vendor user data update. More... | |
default void | OnLocalProxySettings (@NonNull LocalProxySettings settings) |
Local proxy settings update. More... | |
default void | OnFirewallSettings (@NonNull FirewallSettings settings) |
Firewall settings update. More... | |
default void | OnStreamingSettings (@NonNull StreamingSettings settings) |
Streaming settings update. More... | |
default void | OnLocalProxyDomainWatchlistHit (@Nullable String title) |
Called when a domain from a disabled localproxy domainwatchlist is detected. More... | |
default void | OnCaptivePortals (@NonNull List< String > networks) |
Called when captive portals are detected. More... | |
default void | OnServerSettings (@NonNull ServerSettings settings) |
Server settings update. More... | |
default void | OnVPNPermissionResult (boolean hasPermission) |
Result of request for VPN permission. More... | |
default void | OnLastDisconnectEvent (@NonNull DisconnectEvent lastDisconnectEvent) |
Result of request for the last disconnect event. More... | |
default void | OnLogSettings (@NonNull DaemonLogSettings daemon) |
Log settings result. More... | |
default void | OnSpeedTestResults (@NonNull List< SpeedTestResultData > results) |
Speed test result data. More... | |
default void | OnLogReportResult (ErrorType errorType, @Nullable String message, @Nullable String ticketId) |
Result of a log report request. More... | |
![]() | |
default void | OnNetworkSharingSettings (NetworkSharing.Settings settings) |
Network sharing settings. More... | |
default void | OnNetworkSharingDiscovery (boolean discoveryActive) |
Network sharing discovery state. More... | |
default void | OnNetworkSharesAvailable (List< NetworkSharing.Peer > availableShares) |
Available network shares. More... | |
default void | OnNetworkSharingPeerStatusChange (NetworkSharing.PeerRole role, NetworkSharing.PeerUuid uuid, NetworkSharing.PeerStatus peerStatus, NetworkSharing.TunnelStatus tunnelStatus, ErrorType errorType, String errorMessage) |
state changes and connection errors with peers More... | |
default void | OnNetworkSharingPairRequest (NetworkSharing.PeerUuid uuid, String displayName) |
Event when a peer requests a pairing. More... | |
default void | OnNetworkSharingNewPeerAvailable (NetworkSharing.PeerUuid uuid, String displayName) |
Event when a new peer is available. More... | |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnAccountCheckResult | ( | ErrorType | errorType, |
@Nullable String | errorMessage, | ||
boolean | accountExists | ||
) |
Account check result.
errorType | type of the error |
errorMessage | message |
accountExists | if not an error, if the account exists |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnAccountCreateResult | ( | ErrorType | errorType, |
@Nullable String | errorMessage | ||
) |
Account create result.
errorType | type of the error |
errorMessage | message |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnAccountingData | ( | @NonNull AccountingData | accounting | ) |
Accounting data update This can be refreshed with refreshAccounting.
accounting | information on the current account |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnActivationCode | ( | ErrorType | errorType, |
@Nullable String | message, | ||
@NonNull String | activationCode, | ||
@NonNull String | activationUrl | ||
) |
Activation code result.
errorType | type of error |
message | error message |
activationCode | activation code |
activationUrl | activation url |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnAdapterOverlimit | ( | @NonNull String | adapterID, |
NetworkType | type, | ||
@NonNull AdapterUsageData | usageData | ||
) |
Notification when an adapter is near its daily or monthly data usage limit.
This is called at 75% and 100% usage. You must call handleAdapterOverlimit on SpeedifySDK to clear this message. SpeedifyHandler's default implemenation does this automatically.
adapterID | ID of the adapter |
type | type of the adapter |
usageData | information on current usage of the adapter |
Implemented in com.speedify.speedifysdk.SpeedifyHandler.
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnAdaptersList | ( | @NonNull List< AdapterData > | adapters | ) |
Network adapters list update received.
Sent on changes and every 30s while connected to update usage data.
adapters | list of adapters |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnCaptivePortals | ( | @NonNull List< String > | networks | ) |
Called when captive portals are detected.
networks | networks on which a captive portal was detected |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnConnectedServer | ( | @Nullable ServerInformation | serverInfo | ) |
Connected update received.
Send on start of connection attempt and connection completion.
serverInfo | currently connected server |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnConnectError | ( | ErrorType | errorType, |
@Nullable String | message | ||
) |
Error when connecting to a server.
errorType | type of error |
message | error message |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnConnectionStats | ( | @NonNull ConnectionStatsGroup | tunnelStats | ) |
Latest tunnel stats update.
Sent once per second while connected, if tunnel stat updates are enabled. via enableStatUpdates.
tunnelStats | a group of tunnelstats for a point in time |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnConnectionStats | ( | @NonNull List< ConnectionStatsGroup > | tunnelStats | ) |
Historic tunnel stats update.
tunnelStats | list of tunnelstats for a period of time |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnDirectory | ( | @NonNull List< ServerInformation > | servers | ) |
Directory update received This list can be refreshed with refreshDirectory.
servers | list of servers |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnDirectorySettings | ( | @NonNull DirectorySettings | directorySettings | ) |
Directory settings update This can be refreshed with refreshDirectorySettings.
directorySettings | directory settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnFirewallSettings | ( | @NonNull FirewallSettings | settings | ) |
Firewall settings update.
settings | current firewall settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLastDisconnectEvent | ( | @NonNull DisconnectEvent | lastDisconnectEvent | ) |
Result of request for the last disconnect event.
lastDisconnectEvent | the last disconnect event |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLocalProxyDomainWatchlistHit | ( | @Nullable String | title | ) |
Called when a domain from a disabled localproxy domainwatchlist is detected.
title | title of the watchlist that was detected |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLocalProxySettings | ( | @NonNull LocalProxySettings | settings | ) |
Local proxy settings update.
settings | current local proxy settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLocalVendorSettings | ( | @Nullable JSONObject | settings | ) |
Local vendor settings update.
settings | current local vendor settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLoginError | ( | ErrorType | errorType, |
@Nullable String | message | ||
) |
Error when logging in.
errorType | type of error |
message | error message |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLogReportResult | ( | ErrorType | errorType, |
@Nullable String | message, | ||
@Nullable String | ticketId | ||
) |
Result of a log report request.
errorType | type of error |
message | error message |
ticketId | ticket id |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnLogSettings | ( | @NonNull DaemonLogSettings | daemon | ) |
Log settings result.
daemon | log settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnNewAdapter | ( | @NonNull String | adapterID, |
NetworkType | type | ||
) |
Notification for the first time seeing a new adapter.
You must call handleNewAdapter on SpeedifySDK to clear this message. SpeedifyHandler's default implemenation does this automatically.
adapterID | ID of the adapter |
type | type of the adapter |
Implemented in com.speedify.speedifysdk.SpeedifyHandler.
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnNonVPNApplications | ( | @NonNull List< String > | nonVpnApps | ) |
List of apps configured to go around the VPN.
nonVpnApps | app package ids |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnPasswordChangeResult | ( | ErrorType | errorType, |
@Nullable String | errorMessage | ||
) |
Password change result.
errorType | type of the error |
errorMessage | message |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnPrivacySettings | ( | @NonNull PrivacySettings | privacy | ) |
Privacy settings update This can be refreshed with refreshPrivacy.
privacy | privacy settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnRemoteVendorSettings | ( | @Nullable JSONObject | settings | ) |
Remote vendor settings update.
settings | current remote vendor settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnServerSettings | ( | @NonNull ServerSettings | settings | ) |
Server settings update.
settings | current server settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnSessionStats | ( | @NonNull SessionStatPeriods | stats | ) |
Session stats update.
stats | session stat periods object |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnSettingError | ( | @NonNull String | settingAction, |
ErrorType | errorType, | ||
@Nullable String | message | ||
) |
Called in response to an error changing a setting.
settingAction | string identifying the setting that failed to change |
errorType | type of error |
message | error message |
Implemented in com.speedify.speedifysdk.SpeedifyHandler.
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnSettings | ( | @NonNull Settings | settings | ) |
Notification on settings change.
settings | the current settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnSpeedTestResults | ( | @NonNull List< SpeedTestResultData > | results | ) |
Speed test result data.
results | list of speed test results |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnState | ( | State | state | ) |
State update received.
This is sent on state updates, and every 30s while connected.
state | current state |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnStreamingSettings | ( | @NonNull StreamingSettings | settings | ) |
Streaming settings update.
settings | current streaming settings |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnStreamingStats | ( | StreamingStats | stats | ) |
Streaming stats update.
stats | streaming stats object |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnTorrentDetection | ( | boolean | willDisconnect | ) |
A torrent use was detected.
willDisconnect | if this use will trigger a disconnect |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnVendorUserData | ( | @Nullable String | userData | ) |
Vendor user data update.
userData | current vendor user data |
default void com.speedify.speedifysdk.receivers.ISdkStateReceiver.OnVPNPermissionResult | ( | boolean | hasPermission | ) |
Result of request for VPN permission.
hasPermission | whether permission was obtained |