Agora Interactive Whiteboard Java API Reference
|
Public Member Functions | |
void | setCommonCallbacks (CommonCallback commonCallback) |
AudioMixerImplement | getAudioMixerImplement () |
WhiteSdk (JsBridgeInterface bridge, Context context, WhiteSdkConfiguration whiteSdkConfiguration) | |
WhiteSdk (JsBridgeInterface bridge, Context context, WhiteSdkConfiguration whiteSdkConfiguration, @Nullable CommonCallback commonCallback) | |
WhiteSdk (JsBridgeInterface bridge, Context context, WhiteSdkConfiguration whiteSdkConfiguration, UrlInterrupter urlInterrupter) | |
WhiteSdk (JsBridgeInterface bridge, Context context, WhiteSdkConfiguration whiteSdkConfiguration, @Nullable CommonCallback commonCallback, @Nullable AudioMixerBridge audioMixerBridge) | |
void | joinRoom (final RoomParams roomParams, final Promise< Room > roomPromise) |
void | joinRoom (final RoomParams roomParams, final RoomListener roomListener, final Promise< Room > roomPromise) |
void | setupFontFaces (FontFace[] fontFaces) |
void | loadFontFaces (FontFace[] fontFaces, final Promise< JSONObject > loadPromise) |
void | updateTextFont (String[] names) |
void | releaseRoom () |
void | releaseRoom (String uuid) |
void | requestSlideLog (File logFile, final Promise< Boolean > promise) |
void | updateSlideVolume (float volume) |
void | getSlideVolume (Promise< Double > promise) |
void | setSlideListener (SlideListener slideListener) |
Static Public Member Functions | |
static String | Version () |
static void | prepareWhiteConnection (Context context, ConnectionPrepareParam param) |
The WhiteSdk
class.
com.herewhite.sdk.WhiteSdk.WhiteSdk | ( | JsBridgeInterface | bridge, |
Context | context, | ||
WhiteSdkConfiguration | whiteSdkConfiguration | ||
) |
Initializes the WhiteSdk
instance.
Ensure that you call WhiteSdk
to create and initialize a WhiteSdk
instance before calling any other APIs.
bridge | The whiteboard view. See WhiteboardView . |
context | The context of the Android Activity. |
whiteSdkConfiguration | Configurations for the WhiteSdk instance. See WhiteSdkConfiguration . |
com.herewhite.sdk.WhiteSdk.WhiteSdk | ( | JsBridgeInterface | bridge, |
Context | context, | ||
WhiteSdkConfiguration | whiteSdkConfiguration, | ||
@Nullable CommonCallback | commonCallback | ||
) |
Initializes the WhiteSdk
instance.
Ensure that you call WhiteSdk
to create and initialize a WhiteSdk
instance before calling any other APIs.
bridge | The whiteboard view. See WhiteboardView . |
context | The context of the Android Activity. |
whiteSdkConfiguration | Configurations for the WhiteSdk instance. See WhiteSdkConfiguration . |
commonCallback | Common callback events. See CommonCallback . |
com.herewhite.sdk.WhiteSdk.WhiteSdk | ( | JsBridgeInterface | bridge, |
Context | context, | ||
WhiteSdkConfiguration | whiteSdkConfiguration, | ||
UrlInterrupter | urlInterrupter | ||
) |
Initializes the WhiteSdk
instance.
Ensure that you call WhiteSdk
to create and initialize a WhiteSdk
instance before calling any other APIs.
bridge | The whiteboard view, see WhiteboardView . |
context | The context of the Android Activity. |
whiteSdkConfiguration | Configurations for the WhiteSdk instance. See WhiteSdkConfiguration . |
urlInterrupter | Sets the interception of image URL addresses. See UrlInterrupter . |
urlInterrupter
parameter in this method is deprecated. Use the urlInterrupter
method of the CommonCallbacks
interface instead.com.herewhite.sdk.WhiteSdk.WhiteSdk | ( | JsBridgeInterface | bridge, |
Context | context, | ||
WhiteSdkConfiguration | whiteSdkConfiguration, | ||
@Nullable CommonCallback | commonCallback, | ||
@Nullable AudioMixerBridge | audioMixerBridge | ||
) |
Initializes the WhiteSdk
instance.
Ensure that you call WhiteSdk
to create and initialize a WhiteSdk
instance before calling any other APIs.
bridge | The whiteboard view, see WhiteboardView . |
context | The context of the Android Activity. |
whiteSdkConfiguration | Configurations for the WhiteSdk instance. See WhiteSdkConfiguration . |
commonCallback | Common callback events. See CommonCallback . |
audioMixerBridge | Sets audio mixing. See AudioMixerBridge . When you use the Agora RTC SDK and Interactive Whiteboard SDK at the same time, and the dynamic PPT displayed in the whiteboard contains audio files, you can call the AudioMixerBridge interface to play the audio in the dynamic PPT using the Agora RTC SDK interface. |
void com.herewhite.sdk.WhiteSdk.setCommonCallbacks | ( | CommonCallback | commonCallback | ) |
Sets common event callbacks.
The SDK uses the CommonCallback
class to report SDK runtime events to the application.
commonCallback | Common event callbacks. See CommonCallback . |
AudioMixerImplement com.herewhite.sdk.WhiteSdk.getAudioMixerImplement | ( | ) |
Gets the AudioMixerImplement
instance.
AudioMixerImplement
instance.
|
static |
Gets the SDK version number.
"2.12.11"
. void com.herewhite.sdk.WhiteSdk.joinRoom | ( | final RoomParams | roomParams, |
final Promise< Room > | roomPromise | ||
) |
Joins the live Interactive Whiteboard room.
void com.herewhite.sdk.WhiteSdk.joinRoom | ( | final RoomParams | roomParams, |
final RoomListener | roomListener, | ||
final Promise< Room > | roomPromise | ||
) |
Joins the live Interactive Whiteboard room.
roomParams | Configurations for the Room instance. See RoomParams . |
roomListener | Sets room event callbacks. See RoomListener . When the SDK reconnects to the Interactive Whiteboard server, if you do not pass in the roomListener parameter, the SDK uses the previously set roomListener parameter. To release the roomListener , call releaseRoom . |
roomPromise | Promise<Room> interface instance. See Promise . You can get the call result of joinRoom through this interface:
|
void com.herewhite.sdk.WhiteSdk.setupFontFaces | ( | FontFace[] | fontFaces | ) |
Declares the fonts that can be used in the local whiteboard.
The fonts declared by this method can be used to render the characters in PPT and the characters entered by the text tool.
Both this method and loadFontFaces
can declare the fonts to be used in the local whiteboard. The difference is that setupFontFaces
has no callback to report whether the font declaration is successful; loadFontFaces
triggers callbacks to report the preload result of each type of font.
loadFontFaces
method at the same time; otherwise, unexpected results may occur.fontFaces | The specified fonts. See FontFace . |
void com.herewhite.sdk.WhiteSdk.loadFontFaces | ( | FontFace[] | fontFaces, |
final Promise< JSONObject > | loadPromise | ||
) |
Declares the fonts that can be used in the local whiteboard and preloads them.
The fonts declared by this method can be used to render the characters in PPT and the characters entered by the text tool.
Both this method and setupFontFaces
can declare the fonts to be used in the local whiteboard. The difference is that setupFontFaces
has no callback to report whether the font declaration is successful; loadFontFaces
triggers callbacks to report the preload result of each type of fonts.
setupFontFaces
method at the same time; otherwise, unexpected results may occur.void com.herewhite.sdk.WhiteSdk.updateTextFont | ( | String[] | names | ) |
Sets the fonts used by the text tool in the local whiteboard.
names | Names of the fonts. If the specified font does not exist in the user's system, the text tool cannot use the font. Ensure you call setupFontFaces or loadFontFaces to preload the specified font into the local whiteboard. |
void com.herewhite.sdk.WhiteSdk.releaseRoom | ( | ) |
Releases the Room
instance and removes the RoomListener
callback.
void com.herewhite.sdk.WhiteSdk.releaseRoom | ( | String | uuid | ) |
Releases the Room
instance and removes the RoomListener
callback.
releaseRoom
instead.void com.herewhite.sdk.WhiteSdk.requestSlideLog | ( | File | logFile, |
final Promise< Boolean > | promise | ||
) |
Requests the slide log.
logFile | The file that stores the slide log. |
promise | The callback of the request. |
void com.herewhite.sdk.WhiteSdk.updateSlideVolume | ( | float | volume | ) |
Updates the volume of the PPT slide.
volume | Volume. The value range is (0,1]. |
void com.herewhite.sdk.WhiteSdk.getSlideVolume | ( | Promise< Double > | promise | ) |
Gets the volume of the PPT slide.
promise | The result of the method call, including two fields, volume and error :
|
void com.herewhite.sdk.WhiteSdk.setSlideListener | ( | SlideListener | slideListener | ) |
Sets the listener for PPT slides. PPT slides use the SlideListener
class to report events to App.
slideListener | Common callback events. See SlideListener . |
|
static |
Preselects the optimal access domain to improve the connection speed for when the user connects for the first time.
Agora recommends you call this method before joining a whiteboard room, for example, on the device detection page or the whiteboard room list page, thus improving the connection speed when joining a whiteboard room.
context | The context of the Android Activity. |
param | The whiteboard connection preparation parameters, see ConnectionPrepareParam . |