WhiteCommonCallbackDelegate Protocol Reference

Conforms to NSObject
Declared in WhiteCommonCallbacks.h

Overview

Whiteboard common callbacks. The SDK sends callback event notifications to the application.

– throwError:

Reports an uncaught global error during SDK runtime.

- (void)throwError:(NSError *)error

Parameters

error

An error message.

Declared In

WhiteCommonCallbacks.h

– urlInterrupter:

Occurs when the SDK intercepts an image URL address.

- (NSString *)urlInterrupter:(NSString *)url

Parameters

url

The original URL address of an image.

Return Value

The URL address that you specify to replace the original one. Ensure that you set the return value.

Discussion

Note:

  • To trigger this callback, you must set enableInterrupterAPI(YES) to enable the image interception replacement function when initializing the whiteboard SDK. See WhiteSdkConfiguration for details.
  • After the picture interception and replacement function is enabled, the callback will be triggered when a picture or scene is inserted into the whiteboard.

Declared In

WhiteCommonCallbacks.h

– pptMediaPlay

Occurs when the audio and video in dynamic PPT slides start playing.

- (void)pptMediaPlay

Declared In

WhiteCommonCallbacks.h

– pptMediaPause

Occurs when the audio and video in dynamic PPT slides pause playing.

- (void)pptMediaPause

Declared In

WhiteCommonCallbacks.h

– sdkSetupFail:

Reports the failure of the SDK initialization.

- (void)sdkSetupFail:(NSError *)error

Parameters

error

An error message.

Availability

2.9.13

You must initialize a WhiteSDK object before calling any other APIs. You can try reinitializing the SDK.

The SDK initialization failure may be due to the following reasons:

  • Failure to obtain configuration information due to network connection issues.
  • The specified App Identifier is invalid.

Declared In

WhiteCommonCallbacks.h

– customMessage:

Reports the message sent by the webpage.

- (void)customMessage:(NSDictionary *)dict

Parameters

dict

Message in dictionary format. Only when the message is in dictionary format, the local user can receive it.

Discussion

  • Iframe data in dictionary format
  • Image loading failure message
  • PPT play/pause callback information

This callback is triggered when a local user receives a message sent by a web page (such as iframe plug-in, dynamic PPT).

Declared In

WhiteCommonCallbacks.h

– logger:

Gets the local debug logs output by the SDK.

- (void)logger:(NSDictionary *)dict

Parameters

dict

Log messages in dict format. Each log message contains the following keys:

  • funName: The function name.
  • params: Detailed parameter settings.

For example, {"funName": "joinRoom", "params": {"isWritable": 1, "region": "us-sv"}}.

Availability

v2.13.19

After you successfully call log (YES) in WhiteSdkConfiguration, the SDK triggers this callback to send you the local debug logs.

If you need to disable this callback, call log (NO) in WhiteSdkConfiguration.

Note:

After you call log (NO), the SDK stops sending you the local debug logs through this callback, but still triggers this callback to send the logs related to video-js-plugin.

Declared In

WhiteCommonCallbacks.h