23
23
import com .azure .android .communication .ui .calling .models .CallCompositeLocalizationOptions ;
24
24
import com .azure .android .communication .ui .calling .models .CallCompositeMultitaskingOptions ;
25
25
import com .azure .android .communication .ui .calling .models .CallCompositeParticipantViewData ;
26
+ import com .azure .android .communication .ui .calling .models .CallCompositeRoomLocator ;
26
27
import com .azure .android .communication .ui .calling .models .CallCompositeSetupScreenViewData ;
27
28
import com .azure .android .communication .ui .calling .models .CallCompositeCallScreenControlBarOptions ;
28
29
import com .azure .android .communication .ui .calling .models .CallCompositeCallScreenOptions ;
@@ -295,6 +296,9 @@ public void launchComposite(String displayName, String meetingInput, ReadableMap
295
296
if (isUUID ) {
296
297
CallCompositeJoinLocator locator = new CallCompositeGroupCallLocator (UUID .fromString (meetingInput ));
297
298
callComposite .launch (context , locator , localOptions );
299
+ } else if (isRoomsID (meetingInput )) {
300
+ CallCompositeJoinLocator locator = new CallCompositeRoomLocator (meetingInput );
301
+ callComposite .launch (context , locator , localOptions );
298
302
} else {
299
303
List <CommunicationIdentifier > identifiers = new ArrayList <>();
300
304
String [] rawIdArray = meetingInput .split ("," );
@@ -314,6 +318,16 @@ public void launchComposite(String displayName, String meetingInput, ReadableMap
314
318
}
315
319
}
316
320
321
+ private boolean isRoomsID (String meetingInput ) {
322
+ for (int i =0 ;i <meetingInput .length ();i ++) {
323
+ char ch = meetingInput .charAt (i );
324
+ if (!(ch >= '0' && ch <= '9' )) {
325
+ return false ;
326
+ }
327
+ }
328
+ return true ;
329
+ }
330
+
317
331
private String fetchToken () {
318
332
return mToken ;
319
333
}
0 commit comments