rn: add more SDK documentation
This commit is contained in:
parent
f941f15def
commit
2715e81f1d
|
@ -62,6 +62,9 @@ public class JitsiMeetConferenceOptions {
|
||||||
*/
|
*/
|
||||||
private Boolean welcomePageEnabled;
|
private Boolean welcomePageEnabled;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Class used to build the immutable {@link JitsiMeetConferenceOptions} object.
|
||||||
|
*/
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
private URL serverURL;
|
private URL serverURL;
|
||||||
private String room;
|
private String room;
|
||||||
|
@ -78,54 +81,103 @@ public class JitsiMeetConferenceOptions {
|
||||||
public Builder() {
|
public Builder() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**\
|
||||||
|
* Sets the server URL.
|
||||||
|
* @param url - {@link URL} of the server where the conference should take place.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setServerURL(URL url) {
|
public Builder setServerURL(URL url) {
|
||||||
this.serverURL = url;
|
this.serverURL = url;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the room where the conference will take place.
|
||||||
|
* @param room - Name of the room.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setRoom(String room) {
|
public Builder setRoom(String room) {
|
||||||
this.room = room;
|
this.room = room;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the JWT token to be used for authentication when joining a conference.
|
||||||
|
* @param token - The JWT token to be used for authentication.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setToken(String token) {
|
public Builder setToken(String token) {
|
||||||
this.token = token;
|
this.token = token;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the color scheme override so the app is themed. See:
|
||||||
|
* https://github.com/jitsi/jitsi-meet/blob/master/react/features/base/color-scheme/defaultScheme.js
|
||||||
|
* for the structure.
|
||||||
|
* @param colorScheme - A color scheme to be applied to the app.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setColorScheme(Bundle colorScheme) {
|
public Builder setColorScheme(Bundle colorScheme) {
|
||||||
this.colorScheme = colorScheme;
|
this.colorScheme = colorScheme;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates the conference will be joined with the microphone muted.
|
||||||
|
* @param muted - Muted indication.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setAudioMuted(boolean muted) {
|
public Builder setAudioMuted(boolean muted) {
|
||||||
this.audioMuted = muted;
|
this.audioMuted = muted;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates the conference will be joined in audio-only mode. In this mode no video is
|
||||||
|
* sent or received.
|
||||||
|
* @param audioOnly - Audio-mode indicator.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setAudioOnly(boolean audioOnly) {
|
public Builder setAudioOnly(boolean audioOnly) {
|
||||||
this.audioOnly = audioOnly;
|
this.audioOnly = audioOnly;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* Indicates the conference will be joined with the camera muted.
|
||||||
|
* @param videoMuted - Muted indication.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setVideoMuted(boolean videoMuted) {
|
public Builder setVideoMuted(boolean videoMuted) {
|
||||||
this.videoMuted = videoMuted;
|
this.videoMuted = videoMuted;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the welcome page enabled / disabled. The welcome page lists recent meetings and
|
||||||
|
* calendar appointments and it's meant to be used by standalone applications. Defaults to
|
||||||
|
* false.
|
||||||
|
* @param enabled - Whether the welcome page should be enabled or not.
|
||||||
|
* @return - The {@link Builder} object itself so the method calls can be chained.
|
||||||
|
*/
|
||||||
public Builder setWelcomePageEnabled(boolean enabled) {
|
public Builder setWelcomePageEnabled(boolean enabled) {
|
||||||
this.welcomePageEnabled = enabled;
|
this.welcomePageEnabled = enabled;
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Builds the immutable {@link JitsiMeetConferenceOptions} object with the configuration
|
||||||
|
* that this {@link Builder} instance specified.
|
||||||
|
* @return - The built {@link JitsiMeetConferenceOptions} object.
|
||||||
|
*/
|
||||||
public JitsiMeetConferenceOptions build() {
|
public JitsiMeetConferenceOptions build() {
|
||||||
JitsiMeetConferenceOptions options = new JitsiMeetConferenceOptions();
|
JitsiMeetConferenceOptions options = new JitsiMeetConferenceOptions();
|
||||||
|
|
||||||
|
|
|
@ -133,7 +133,8 @@ public class JitsiMeetView extends BaseReactView<JitsiMeetViewListener> {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Joins the conference specified by the given {@link JitsiMeetConferenceOptions}.
|
* Joins the conference specified by the given {@link JitsiMeetConferenceOptions}. If there is
|
||||||
|
* already an active conference, it will be left and the new one will be joined.
|
||||||
* @param options - Description of what conference must be joined and what options will be used
|
* @param options - Description of what conference must be joined and what options will be used
|
||||||
* when doing so.
|
* when doing so.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -35,7 +35,9 @@ public interface JitsiMeetViewListener {
|
||||||
*
|
*
|
||||||
* @param data Map with an "error" key with the error and a "url" key with
|
* @param data Map with an "error" key with the error and a "url" key with
|
||||||
* the conference URL. If the conference finished gracefully no `error`
|
* the conference URL. If the conference finished gracefully no `error`
|
||||||
* key will be present.
|
* key will be present. The possible values for "error" are described here:
|
||||||
|
* https://github.com/jitsi/lib-jitsi-meet/blob/master/JitsiConnectionErrors.js
|
||||||
|
* https://github.com/jitsi/lib-jitsi-meet/blob/master/JitsiConferenceErrors.js
|
||||||
*/
|
*/
|
||||||
void onConferenceTerminated(Map<String, Object> data);
|
void onConferenceTerminated(Map<String, Object> data);
|
||||||
|
|
||||||
|
|
|
@ -18,16 +18,37 @@
|
||||||
|
|
||||||
@interface JitsiMeetConferenceOptionsBuilder : NSObject
|
@interface JitsiMeetConferenceOptionsBuilder : NSObject
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Server where the conference should take place.
|
||||||
|
*/
|
||||||
@property (nonatomic, copy, nullable) NSURL *serverURL;
|
@property (nonatomic, copy, nullable) NSURL *serverURL;
|
||||||
|
/**
|
||||||
|
* Room name.
|
||||||
|
*/
|
||||||
@property (nonatomic, copy, nullable) NSString *room;
|
@property (nonatomic, copy, nullable) NSString *room;
|
||||||
|
/**
|
||||||
|
* JWT token used for authentication.
|
||||||
|
*/
|
||||||
@property (nonatomic, copy, nullable) NSString *token;
|
@property (nonatomic, copy, nullable) NSString *token;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Color scheme override, see:
|
||||||
|
* https://github.com/jitsi/jitsi-meet/blob/master/react/features/base/color-scheme/defaultScheme.js
|
||||||
|
*/
|
||||||
@property (nonatomic, copy, nullable) NSDictionary *colorScheme;
|
@property (nonatomic, copy, nullable) NSDictionary *colorScheme;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set to YES to join the conference with audio / video muted or to start in audio
|
||||||
|
* only mode respectively.
|
||||||
|
*/
|
||||||
@property (nonatomic) BOOL audioOnly;
|
@property (nonatomic) BOOL audioOnly;
|
||||||
@property (nonatomic) BOOL audioMuted;
|
@property (nonatomic) BOOL audioMuted;
|
||||||
@property (nonatomic) BOOL videoMuted;
|
@property (nonatomic) BOOL videoMuted;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set to YES to enable the welcome page. Typically SDK users won't need this enabled
|
||||||
|
* since the host application decides which meeting to join.
|
||||||
|
*/
|
||||||
@property (nonatomic) BOOL welcomePageEnabled;
|
@property (nonatomic) BOOL welcomePageEnabled;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
|
@ -27,7 +27,9 @@
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Joins the conference specified by the given options. The gievn options will
|
* Joins the conference specified by the given options. The gievn options will
|
||||||
* be merged with the defaultConferenceOptions (if set) in JitsiMeet.
|
* be merged with the defaultConferenceOptions (if set) in JitsiMeet. If there
|
||||||
|
* is an already active conference it will be automatically left prior to
|
||||||
|
* joining the new one.
|
||||||
*/
|
*/
|
||||||
- (void)join:(JitsiMeetConferenceOptions *)options;
|
- (void)join:(JitsiMeetConferenceOptions *)options;
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -31,7 +31,9 @@
|
||||||
*
|
*
|
||||||
* The `data` dictionary contains an `error` key with the error and a `url` key
|
* The `data` dictionary contains an `error` key with the error and a `url` key
|
||||||
* with the conference URL. If the conference finished gracefully no `error`
|
* with the conference URL. If the conference finished gracefully no `error`
|
||||||
* key will be present.
|
* key will be present. The possible values for "error" are described here:
|
||||||
|
* https://github.com/jitsi/lib-jitsi-meet/blob/master/JitsiConnectionErrors.js
|
||||||
|
* https://github.com/jitsi/lib-jitsi-meet/blob/master/JitsiConferenceErrors.js
|
||||||
*/
|
*/
|
||||||
- (void)conferenceTerminated:(NSDictionary *)data;
|
- (void)conferenceTerminated:(NSDictionary *)data;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue