.NET Functions
.NET Functions
Functions for .NET are divided into platform-specific ones, which are available separately for each platform (Android, iOS), and common ones, which are identical across all platforms.
Functions for Android
The following is a list of functions used exclusively for Android development.
Init
Function for initializing an Android SDK object with platform-specific parameters.
Parameters:
activity– the current Activity for initializing all activities and services (Activity).
AddCustomButtons
The feature for adding additional custom buttons to the conference control panel.
Parameters:
extraButtons– an array of buttons of typeTCExtraButton.
GetTrueConfAppContext
Retrieving context from the Android SDK.
Return value: application context (Context).
Functions for iOS
Below is a list of functions used exclusively for iOS development.
Init
Function for initializing an iOS SDK object with platform-specific parameters.
Parameters:
uiApplication– the currentUIApplicationused for managing application controllers.
AddCustomButtons
The feature for adding additional custom buttons to the conference control panel.
Parameters:
extraButtons– an array of buttons of theTCSDKExtraButtontype.
PresentViewController
Displaying a new UIViewController over the conference window.
Parameters:
controller– a controller for displaying over the conference window (UIViewController);animated– appearance animation of the controller (bool);sender– parent controller (NSObject);completionHandler– the action that will be executed after the controller appears (Action).
General Features
Below is a list of common features that are identical across all platforms.
Start
Launching the SDK after completing the initial setup.
Parameters:
server(optional) - the server to connect to (string).
Stop
Stopping the SDK instance and releasing resources.
LoginAs
Authorization as a specific user with specified parameters on the server.
Parameters:
user- user ID (string);password– password (string);encryptPassword–trueif the password is transmitted in plain text (and the SDK needs to encrypt it),falseif it is already encrypted (bool);enableAutoLogin– whether to automatically authenticate the user with this ID upon re-launch (bool).
Return value (bool) – true if the authorization request is sent to the server, false if the authorization cannot be performed.
Logout
Deauthorize (log out) an account without disconnecting the SDK from the video conferencing server.
Return value (bool) – true if the deauthorization request was sent to the server, false if deauthorization cannot be performed.
CallTo
Call the specified subscriber.
Parameters:
user– TrueConf ID of the called party (string).
The return value (bool) is true if the call is sent to the server, false if the call cannot be made.
JoinConf
Connecting to a group conference.
Parameters:
conferenceId– conference identifier (string).
The return value (bool) is true if the call is sent to the server, false if the call cannot be made.
Hangup
Ending the current call or conference.
Parameters:
forAll(optional) – in the case of a conference, determines whether it should be ended for all participants if authorized (bool). The default istrue.
Return value (boolean) — true if the call can be ended, false if the call cannot be ended (usually due to an incorrect state).
AcceptCall
Answering an incoming call.
Parameters:
accept– accept or decline a call (bool).
Return value (bool) – true if a response to the request can be made, false if a response is not possible.
ParseProtocolLink
The function receives a command as a string, detailing which server to connect to, which account to use for authentication, and which call to make. It then automatically performs all these operations.
Parameters:
cmd- the string being processed (string).
ScheduleLoginAs
Retrieving a list of operations that need to be performed sequentially, including the server to connect to, account credentials, and the call recipient's details. This is equivalent to the function ParseProtocolLink, where parameters are provided separately rather than as a protocol string. String parameters may be empty.
Parameters:
login– user ID (string);pwd– password (string);encryptPassword–trueif the password is transmitted in plain text (and the SDK needs to encrypt it),falseif it is already encrypted (bool);callToUser– identifier of the called user (string);autoClose– indicates whether to close the session with the server after completing a call or interrupting execution (bool);loginTemp– indicates a temporary login. It means that the client should be logged out after the call (bool);loginForce– forced login. Authentication will occur even if the client is already authenticated on the server (bool);domain- the domain in which the automatic server search will be performed (string);serversList– a list of servers to connect to (string);isPublic- a parameter indicating thatcallToUseris the name of a conference, not a user name. If this parameter is incorrect, the call to the user or connection to the conference will not be successful (bool).
MuteMicrophone
Changing the microphone status.
Parameters:
mute– the state to set the microphone:true– microphone is off,false– microphone is on (boolean).
MuteCamera
Camera status change.
Parameters:
mute– the state to set the camera to:true– camera off,false– camera on (bool).
GetMyId
Obtaining your personal ID.
Return value (string): the identifier of the current user in the system.
GetMyName
Retrieving your own display name for the interface.
Returned value (string): the name of the current user.
IsStarted
Checking the operational status of the SDK instance (bool).
IsConnectedToServer
Checking connection to the server.
Return value (bool) - true if there is a connection to the server, false if there is no connection.
IsLoggedIn
Checking authorization status.
Return value (bool) – true, the user is authorized on the server; false – the user is not authorized.
IsInConference
Checking conference participation.
Return value (bool) – true, the client is in a conference; false, the client is not in a conference.
GetUserStatus
Fetching the status of another user. If the status is known, it is returned immediately. If not, the status is requested from the server, and the client subscribes to notifications about its changes.
Parameters:
user– TrueConf ID of the user whose status is being requested (string).
Return value (TUserPresStatus) – the current status of the user.
IsMicrophoneMuted
Checking the microphone status.
Return value (bool) – true when the camera is off, false when the camera is on.
IsCameraMuted
Checking the camera status.
Return value (bool) – true when the camera is off, false when the camera is on.
AcceptRecord
Response to an incoming video recording request.
Parameters:
accept– accept or decline a video recording request (bool);userID– TrueConf ID of the user to whom the response to the request is given (string).
SendChatMessage
Sending a text message.
Parameters:
userID– the TrueConf ID of the user to whom the message is being sent (it is recommended to use the full ID in the formatuser@server.name) (string). To send a message to the chat of the current group conference, this parameter should be empty.message– message text (string).
Return value (boolean) – true if the message is sent to the server, false if the message fails to send due to lack of server connection.
