Rtcc Class Reference

Inherits from NSObject
Declared in Rtcc.h

Other Methods

  publicIP

The public IP your client is using.

@property (nonatomic, readonly) NSString *publicIP
Availability

5.6

Discussion

The public IP your client is using.

Declared In

Rtcc.h

– sipID

Connection’s Session ID

- (NSString *)sipID
Discussion

Connection’s Session ID

Declared In

Rtcc.h

  delegate

Delegate for the SDK instance. Implements RtccDelegate’s protocol.

@property (nonatomic, weak) id<RtccDelegate> delegate
Availability

5.0

Declared In

Rtcc.h

+ logger

The delegate used for logs. This delegate is set using setLogger:.

+ (id<RtccLogDelegate>)logger
Discussion

The delegate used for logs. This delegate is set using setLogger:.

See Also
  • + setLogger: for discussion about how the object pointer is kept.

Declared In

Rtcc.h

+ setLogger:

  • @brief Setting the logger is best done before Rtcc creation.
  • @discussion The variable is not kept as a property of the Rtcc object, but as a global variable. Calling reset on the Rtcc object set that global variable to nil.
+ (void)setLogger:(id<RtccLogDelegate>)logger
Parameters
logger

The object that will do the logging.

Discussion
  • @brief Setting the logger is best done before Rtcc creation.
  • @discussion The variable is not kept as a property of the Rtcc object, but as a global variable. Calling reset on the Rtcc object set that global variable to nil.
Declared In

Rtcc.h

  connected

YES if the RTCC instance is connected.

@property (nonatomic, getter=isConnected, readonly) BOOL connected
Availability

5.0

Declared In

Rtcc.h

  authenticated

YES if the RTCC instance is authenticated.

@property (nonatomic, getter=isAuthenticated, readonly) BOOL authenticated
Availability

5.0

Declared In

Rtcc.h

  activeCall

The current active call, if any.

Currently, only one call at a time is supported.

@property (nonatomic, readonly) RtccCall *activeCall
Availability

5.0

Declared In

Rtcc.h

  currentStatus

Allows the app to fetch the current SDK status.

Not KVO compliant since 6.3.

@property (nonatomic, readonly) sdkStatus_t currentStatus
Availability

5.4

Declared In

Rtcc.h

  displayName

The display name used by the application.

Set this before placing a call to ensure the call can be created.

@property (nonatomic, strong) NSString *displayName
Availability

5.0

Declared In

Rtcc.h

Delegates

  presenceDelegate

The presence Delegate, implements RtccPresenceDelegate’s protocol. It will be called for every presence or roster events.

Upon logon, the user is registered to a presence system. This allows users to set their presence, Create, Update, Fetch and Delete a contact roster and be notified of a registered Contact’s Presence change. The Registration happens automatically upon authentication. The Delegate is notified of the event through [RtccPresenceDelegate rtccPresenceRegistrationUpdate:]

Setting one’s presence is done through a call to [Rtcc setPresence:]. A presence value is merely a uint8_t, its interpretation is left to the host app, beside 0, which is the value returned when fetching the Presence of a non registered Contact.

Registering a roster (a.k.a. a list of contacts) is done using [Rtcc addContactsToRoster:].

@property (nonatomic, weak) id<RtccPresenceDelegate> presenceDelegate
Declared In

Rtcc.h

  dataDelegate

The delegate to whom the answers to the Data method will be sent.

Implements RtccDataDelegate’s protocol.

@property (nonatomic, weak) id<RtccDataDelegate> dataDelegate
Availability

5.4

Declared In

Rtcc.h

  meetingDelegate

Delegate that implements the meeting point callbacks.

Implements RtccMeetingPointDelegate’s protocol.

@property (nonatomic, weak) id<RtccMeetingPointDelegate> meetingDelegate
Availability

5.3

Declared In

Rtcc.h

  hostDelegate

Delegate that implements the host delegate.

Implements RtccHostDelegate’s protocol. Will be notified of Meeting point creation, destruction, user trying to join, etc

@property (nonatomic, weak) id<RtccHostDelegate> hostDelegate
Availability

5.3

Declared In

Rtcc.h

  attendeeDelegate

Delegate that implements the attendee delegate.

Implements RtccAttendeeDelegate’s protocol. Implement it to be notified of invitation and acceptance status.

@property (nonatomic, weak) id<RtccAttendeeDelegate> attendeeDelegate
Availability

5.3

Declared In

Rtcc.h

Getting and initializing

+ instance

Returns the Rtcc singleton instance. If not instantiated, it will be instantiated then.

+ (Rtcc *)instance
Return Value

The Rtcc singleton.

Availability

5.0

Declared In

Rtcc.h

– connectWithAppID:andUserType:

- (void)connectWithAppID:(NSString *)appID andUserType:(UserType *)ut
Parameters
appID

Your AppID

ut

The user information to use for authentication

Discussion
Declared In

Rtcc.h

– connectWithAppID:andUserType:onPlatform:

- (void)connectWithAppID:(NSString *)appID andUserType:(UserType *)ut onPlatform:(NSDictionary *)platform
Parameters
appID

Your AppID

ut

The user information to use for authentication

platform

The platform to connect to

Discussion
Declared In

Rtcc.h

– getMetrics

Some information about the connection, such as the short name of the platform we are connected to and the RTT to that platform.

- (RtccMetricsConnection *)getMetrics
Return Value

Some information about the connection, such as the short name of the platform we are connected to and the RTT to that platform.

Declared In

Rtcc.h

+ getVersion

Used for identification purpose.

+ (NSString *)getVersion
Return Value

The version of the Rtcc SDK.

Availability

5.0

Discussion

Used for identification purpose.

Declared In

Rtcc.h

+ reset

Reset the whole thing. Connection is dropped and data forgotten.

+ (void)reset
Availability

5.0

Discussion

Reset the whole thing. Connection is dropped and data forgotten.

Declared In

Rtcc.h

Log files

+ setLogLevel:

Set the log level currently used.

+ (void)setLogLevel:(logLevel_t)logLevel
Parameters
logLevel

The logLevel to set.

Availability

5.1

Discussion

Set the log level currently used.

Declared In

Rtcc.h

+ getLogLevel

Returns the current log level.

+ (logLevel_t)getLogLevel
Availability

5.1

Discussion

Returns the current log level.

Declared In

Rtcc.h

Connection and status

– disconnect

Disconnects from rtcc servers.

A call to [RtccDelegate rtccDidDisconnect:] is to be expected upon disconnection.

- (void)disconnect
Availability

5.0

Declared In

Rtcc.h

Create a call

– createCallWithOptions:

Creates a call using a dictionary of parameters.

This method is eventually called by all the others of the Rtcc createCall: family. Note that certain key/values of the dictionary are mandatory. The others falls back to default values presented in the following list. All keys are defined in RtccData.h .

- (void)createCallWithOptions:(NSDictionary *)options
Parameters
options

The parameters to use to create the call. Possible keys are defined in RtccData.h: - k_ContactID: the ID of the contact to call. NSString. Mandatory. - k_ContactDN: the display name of the person you are calling. NSString. Mandatory. - k_WithVideo: YES (as a NSNumber) will see the app send a video stream on call start. Default is YES. - k_WithAudio: A NSNumber from an int, based on the rawValue of the wanted audioMode_t. - k_VideoStartProfile: @“md” will see the app start in VGA outgoing stream or CIF profile otherwise. Default is @“sd”. - k_AudioRoute: A NSNumber from an int, based on the rawValue of the wanted audioRoute_t. - k_User

Availability

5.3

Declared In

Rtcc.h

– createCall:

Creates a call whose recipient is contactUID.

The call is immediately created. If the callee is not available, the call is ended almost immediately. The call is returned to the application throught the use of the [RtccDelegate rtccCallCreated:] method. Similar to call [Rtcc createCallWithOptions:] with @{k_ContactID:contactUID, k_ContactDN:contactUID} as argument.

- (void)createCall:(NSString *)contactUID
Parameters
contactUID

The UID of the contact or the conference to call. Must not be nil.

Availability

5.0

Declared In

Rtcc.h

– createCall:andSetDisplayName:

Creates a call whose recipient is contactUID and set the contact’s display name to displayName.

The call is immediately created. If the callee is not available, the call is ended almost immediately. The call is returned to the application throught the use of the [RtccDelegate rtccCallCreated:] method. Similar to call [Rtcc createCallWithOptions:] with @{k_ContactID:contactUID, k_ContactDN:displayName} as argument.

- (void)createCall:(NSString *)contactUID andSetDisplayName:(NSString *)displayName
Parameters
contactUID

The ID of the contact or the conference to call. Must not be nil.

displayName

The contact display name to be used. Must not be nil.

Availability

5.0

Declared In

Rtcc.h

– createCall:andSetDisplayName:withVideo:

Creates a call whose recipient is contactUID and set the contact’s display name to displayName.

The call is immediately created. If the callee is not available, the call is ended almost immediately. The call is returned to the application throught the use of [RtccDelegate rtccCallCreated:] method. Similar to call [Rtcc createCallWithOptions:] with @{k_ContactID:contactUID, k_ContactDN:displayName, k_WithVideo:@1} as argument.

- (void)createCall:(NSString *)contactUID andSetDisplayName:(NSString *)displayName withVideo:(BOOL)videoEnabled
Parameters
contactUID

The ID of the contact or the conference to call. Must not be nil.

displayName

The contact display name to be used. Must not be nil.

videoEnabled

YES if the call should have videoOut enable by the time the remote picks up.

Availability

5.2

Declared In

Rtcc.h

Media rate overrides

– overrideVideoFPS:andVideoMaxBitrate:andResolutionDivider:

Overrides internals values.

Overrides the default bandwidth parameters by changing the max video FPS and bandwith, and adding a resolution divider. Settings any of this value to 0 will reset the setting to default values.

- (void)overrideVideoFPS:(int)maxfps andVideoMaxBitrate:(int)maxBitrate andResolutionDivider:(int)resolutionDiv
Parameters
maxfps

The max FPS wanted from the encoder. valid values are 1-30. Set to 0 to get back to defaults.

maxBitrate

Max bitrate for the video encding. 1-1000000, unit is bps.

resolutionDiv

Values are 1 or 2. Setting 2 will divide the video frame dimension by 2 (i.e. 352288 becomes 176144).

Availability

5.1

Declared In

Rtcc.h

– overrideAudioComplexity:andAudioBitrate:andVideoCPUUsage:

Overrides two audio encoding parameters and the CPU usage of the video encoder.

- (void)overrideAudioComplexity:(int)complexity andAudioBitrate:(int)bitrate andVideoCPUUsage:(int)cpuusage
Parameters
complexity

The complexity used for the audio encoding. 0-10, 10 is better quality, more cpu consuming. Default is 4.

bitrate

The audio bitrate in bps. 16000 - 64000. default is 24000.

cpuusage

The cpu usage of the video encoder. 0-16, 0 being the most intensive. default is 8.

Availability

5.2

Declared In

Rtcc.h

– resetBandwidthDefaults

Restore defaults bandwidth parameters.

Equivalent to call [Rtcc overrideVideoFPS:andVideoMaxBitrate:andResolutionDivider:] with 0 as parameters.

- (void)resetBandwidthDefaults
Availability

5.1

Declared In

Rtcc.h

Handle the presence

– getPresenceForContacts:

Fetches the status for the contacts UID in the array.

If contactsUID is nil, the whole roster is returned throught [RtccPresenceDelegate rtccRosterUpdate:].

- (void)getPresenceForContacts:(NSArray *)contactsUID
Parameters
contactsUID

An array of UIDs. All components of the array must be of type NSString *. If nil, fetches the whole roster.

Availability

5.4

Declared In

Rtcc.h

– setPresence:

This allows users to change their presence status.

This calls in return the [RtccPresenceDelegate rtccPresenceContact:changedPresence:] with your current presence.

- (void)setPresence:(uint8_t)presence
Parameters
presence

The significance of the value is left to the host App.

Availability

5.4

Declared In

Rtcc.h

– addContactsToRoster:

Adding contacts to the roster.

- (void)addContactsToRoster:(NSArray *)contactsUID
Parameters
contactsUID

Contact UIDs to add to the roster. All components of the array must be of type NSString *. If nil, nothing is done.

Availability

5.4

Declared In

Rtcc.h

– removeContactsFromRoster:

Removes the UID contained in contactsUID from the roster.

Use nil to clear the roster.

- (void)removeContactsFromRoster:(NSArray *)contactsUID
Parameters
contactsUID

The list of contacts to be removed from the roster. All components of the array must be of type NSString *. If nil, the roster is cleared.

Availability

5.4

Declared In

Rtcc.h

Send and Receive Data

– dataAcknowledge:ofContact:withFlag:

Used to acknowledge a message received through [RtccDataDelegate rtccReceivedData:from:withID:].

- (void)dataAcknowledge:(int32_t)messageID ofContact:(NSString *)contactUID withFlag:(uint8_t)flag
Parameters
messageID

The ID of the message to acknowledge

contactUID

The UID of the sender. Must not be nil.

flag

A host application defined value, send to the remote contact who first sent the message.

Declared In

Rtcc.h

– dataSend:toContactUIDs:withID:

Sends data to a contact.

This data is received by the contact through [RtccDataDelegate rtccReceivedData:from:withID:]

- (void)dataSend:(NSData *)data toContactUIDs:(NSArray *)contactUIDs withID:(int32_t)messageID
Parameters
data

The data to send. Must not be nil.

contactUIDs

The UID of the contacts to which the message will be sent. Must not be nil.

messageID

The ID of the message

Declared In

Rtcc.h

Meeting Point: Host controls

– meetingPointCreateWithTitle:atLocation:startDate:endDate:withType:

Creates a MeetingPoint based on values.

Asynchronous call. Host only.

- (void)meetingPointCreateWithTitle:(NSString *)title atLocation:(NSString *)location startDate:(NSDate *)startDate endDate:(NSDate *)endDate withType:(mpType_t)mpType
Parameters
title

The title of the meeting point. 128 char. max

location

The location of the meeting. 128 char. max.

startDate

The date at which the call will start.

endDate

The date at which the call will end.

mpType

The meeting type.

Availability

5.3

Discussion

Warning: 5.3: For the key mpType, the value mpType_adHoc is not yet supported

Declared In

Rtcc.h

– meetingPointUpdate:newTitle:newLocation:newStartDate:newEndDate:

Changes the writable informations of the meeting point.

Asychronous call. Host only.

- (void)meetingPointUpdate:(NSString *)mpID newTitle:(NSString *)title newLocation:(NSString *)location newStartDate:(NSDate *)startDate newEndDate:(NSDate *)endDate
Parameters
mpID

The internal name of the meeting point that was returned after a creation callback. Must not be nil.

title

The title of the meeting point. 128 char. max

location

The location of the meeting. 128 char. max.

startDate

The date at which the call will start.

endDate

The date at which the call will end.

Availability

5.3

Declared In

Rtcc.h

– meetingPointLock:

Locks the meeting point.

Equivalent to [Rtcc meetingPoint:setAuthorizationStatus:] with mpSta_autodeny as status.

- (void)meetingPointLock:(NSString *)mpID
Parameters
mpID

The ID of the meeting point we want to lock. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPoint:setAuthorizationStatus:

Changes the meeting point automatic authorization behaviour.

Attendees-to-be will be answered to automatically if status is mpSta_autoaccept or mpSta_autodeny.

- (void)meetingPoint:(NSString *)mpID setAuthorizationStatus:(mpAuthorizationMode_t)status
Parameters
mpID

The ID of the meeting point we want to lock. Must not be nil.

status

One of mpAuthorizationMode_t;

Availability

5.3

Declared In

Rtcc.h

– meetingPointGetDetails:

Returns details about the meeting point.

Asynchronous call.

- (void)meetingPointGetDetails:(NSString *)mpID
Parameters
mpID

The meeting point id. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointContactList:

Returns the list of contacts in the meeting point.

Asynchronous call.

- (void)meetingPointContactList:(NSString *)mpID
Parameters
mpID

The meeting point id. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointDelete:

Deletes the meeting point from the system.

Host only.

- (void)meetingPointDelete:(NSString *)mpID
Parameters
mpID

The ID of the meeting point we want to delete. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointStart:

Starts the meeting point.

To be called only the host after this MP was created.

- (void)meetingPointStart:(NSString *)mpID
Parameters
mpID

The ID of the meeting point. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointStop:

Stops the meeting point.

Host only.

- (void)meetingPointStop:(NSString *)mpID
Parameters
mpID

The ID of the meeting point. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointJoinConferenceHost:

Create the conference call related to the meeting point.

It is only after this call is created and started that the Host can accept or deny attendees. This method can only be called after the meeting point is started through [Rtcc meetingPointStart:].

- (void)meetingPointJoinConferenceHost:(NSString *)mpID
Parameters
mpID

The ID of the meeting point. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointJoinConferenceHost:withOptions:

Create the conference call related to the meeting point.

It is only after this call is created and started that the Host can accept or deny attendees. This method can only be called after the meeting point is started through [Rtcc meetingPointStart:]. The additional parameters are used to configure the call.

- (void)meetingPointJoinConferenceHost:(NSString *)mpID withOptions:(NSDictionary *)parameters
Parameters
mpID

The ID of the meeting point. Must not be nil.

parameters

The call parameters.

Declared In

Rtcc.h

– meetingPoint:acceptUser:

Accept an attendee in the conference.

The related call must have been created. Host only.

- (void)meetingPoint:(NSString *)mpID acceptUser:(NSString *)contactUID
Parameters
mpID

The ID of the meeting point. Must not be nil.

contactUID

The ID of the user to be accepted. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPoint:denyUser:

Denies an attendee access to the conference.

The related call must have been created. Host only.

- (void)meetingPoint:(NSString *)mpID denyUser:(NSString *)contactUID
Parameters
mpID

The ID of the meeting point. Must not be nil.

contactUID

The ID of the user. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPoint:inviteUser:

Invites a user to a meeting point.

The related call must have been created. Host only.

- (void)meetingPoint:(NSString *)mpID inviteUser:(NSString *)contactUID
Parameters
mpID

The ID of the meeting point. Must not be nil.

contactUID

The ID of the contact we want to invite. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPoint:cancelInviteTo:

Cancels the invitation sent by [Rtcc meetingPoint:inviteUser:].

Host Only.

- (void)meetingPoint:(NSString *)mpID cancelInviteTo:(NSString *)contactUID
Parameters
mpID

The ID of the meeting point. Must not be nil.

contactUID

The ID of the contact whose invitation will be revoked. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

Meeting Point: Attendee controls

– meetingPointRequestJoin:

Asks to join a meeting point as an attendee.

- (void)meetingPointRequestJoin:(NSString *)mpID
Parameters
mpID

The ID of the meeting point we want to join. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointCancelJoinRequest:

Cancels the join request.

- (void)meetingPointCancelJoinRequest:(NSString *)mpID
Parameters
mpID

The ID of the meeting point we wanted to join. Must not be nil.

Availability

5.3

Declared In

Rtcc.h

– meetingPointJoinConferenceAttendee:

Call the meeting point as attendee.

This should be called only if already accepted (i.e. in response to a [RtccAttendeeDelegate rtccAttendeeAuthorization:forMeeting:] with mpAtt_accepted as first param).

- (void)meetingPointJoinConferenceAttendee:(NSString *)mpID
Parameters
mpID

The meeting point ID. Must not be nil.

Availability

5.3

Discussion

Warning: To be called only after the host accepts the join request or the attendee receives an invite. Calling otherwise will lead to a call error.

Declared In

Rtcc.h

– meetingPointJoinConferenceAttendee:withOptions:

Call the meeting point as attendee.

This should be called only if already accepted (i.e. in response to a [RtccAttendeeDelegate rtccAttendeeAuthorization:forMeeting:] with mpAtt_accepted as first param).

- (void)meetingPointJoinConferenceAttendee:(NSString *)mpID withOptions:(NSDictionary *)parameters
Parameters
mpID

The meeting point ID. Must not be nil.

parameters

Those parameters are used to configure the call.

Discussion

Warning: To be called only after the host accepts the join request or the attendee receives an invite. Calling otherwise will lead to a call error.

Declared In

Rtcc.h

– meetingPoint:attendeeAnswersToInvite:

Used by an attendee to respond to an invitation to join a meeting point.

Attendee Only. Should be send in response to a [RtccAttendeeDelegate rtccAttendeeWasInvitedToMeeting:]. (Deprecated: Since 6.3 Please use [Rtcc meetingPoint:attendeeAnswersToInvite:from:])

- (void)meetingPoint:(NSString *)mpID attendeeAnswersToInvite:(BOOL)accept
Parameters
mpID

The meeting point ID. Must not be nil.

accept

YES if the attendee accepts to join the meeting point. NO if not.

Availability

5.3

Declared In

Rtcc.h

– meetingPoint:attendeeAnswersToInvite:from:

Used by an attendee to respond to an invitation to join a meeting point.

Attendee Only. Should be send in response to a [RtccAttendeeDelegate rtccAttendeeWasInvitedToMeeting:byUser:].

- (void)meetingPoint:(NSString *)mpID attendeeAnswersToInvite:(BOOL)accept from:(NSString *)userUID
Parameters
mpID

The meeting point ID. Must not be nil.

accept

YES if the attendee accepts to join the meeting point. NO if not.

userUID

The user who sent that invitation.

Availability

6.3

Declared In

Rtcc.h

– meetingPoint:joinWithHash:

Join a meeting point using its ID and a hash.

The only way to have a hash is to be accepted beforehand.

- (void)meetingPoint:(NSString *)mpID joinWithHash:(NSString *)hash
Parameters
mpID

The meeting point ID. Must not be nil.

hash

The hash for the Meeting Point. Provided by an implementation of JS in standalone mode.

Availability

5.4.1

Declared In

Rtcc.h

– requestACDforValue:andMask:

Send an ACD request.

- (void)requestACDforValue:(uint64_t)value andMask:(uint64_t)mask
Parameters
value

Configuration of the product

mask

Mask of the product

Discussion

Send an ACD request.

Declared In

Rtcc.h

– requestACDCancel

Cancel ACD Request. Call it before disconnecting during an ACD request.

- (void)requestACDCancel
Discussion

Cancel ACD Request. Call it before disconnecting during an ACD request.

Declared In

Rtcc.h