Classes(Swift)
-
BJNObservable
is a generic type that generates a callback when its value is changed. It can be used to listen in on changes to a specific value, but not to update the value itself.BJNObservable
is read-only, for write capabilities, seeBJNMutableObservable
Monitor any change to the value as:
See moreclientMuteState.onChange { print("the client is now \(clientMuteState.value ? "muted" : "unmuted")") }
Declaration
Swift
public class BJNObservable<T>
-
BJNMutableObservable
is aBJNObservable
that allows its value to be changed.To modify a
BJNMutableObservable
‘s value,mutableObservableVar.value = true
As a subclass of
BJNObservable
, you can still listen in on value changes.
See moremutableObservableVar.onChange { print("value changed to ", mutableObservableVar.value) }
Declaration
Swift
public class BJNMutableObservable<T> : BJNObservable<T>
-
BJNVideo
encapsulates all of the BlueJeans API related to establishing an audio/video connection.It can be initialized as,
let video = BJNVideo()
To connect to an audio/video meeting,
video.join(meetingID: "111111111", passcode: "2222", displayName: "John Doe", onSuccess: { print("Successfully joined the meeting") }, onFailure: {})
To disconnect from the meeting,
video.leave()
BJNVideo
has several observable properties, some of which can be mutated.All properties (
BJNObservable
andBJNMutableObservable
) can be observed,video.videoMuted.onChange { print("video muted status changed to ", video.videoMuted.value) }
and any properties that are of type
BJNMutableObservable
can be modified
See morevideo.videoMuted.value = true
Declaration
Swift
public class BJNVideo