无法在我的应用程序中集成缩放 [英] Not able to integrate zoom in my application
问题描述
我正在尝试将缩放集成到我的应用程序中.为此,我点击了此链接[https://marketplace.zoom.us/docs/sdk/native-sdks/android/getting-started/prerequisites]
I am trying to integrate zoom in my application. For that, I followed this link [https://marketplace.zoom.us/docs/sdk/native-sdks/android/getting-started/prerequisites]
我创建了一个新的android项目,在其中我从zoom SDK中导入了.aar文件并导入了依赖项,但是当我尝试在主应用程序中运行它时,出现此错误.
I've created a new android project where I've imported the .aar files from zoom SDK as well as imported the dependencies but when I try to run this in my main application I get this error.
error: cannot find symbol
JoinMeetingOptions opts = ZoomMeetingUISettingHelper.getJoinMeetingOptions();
^
symbol: variable ZoomMeetingUISettingHelper
location: class MainActivity
依赖项
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation project(path: ':commonlib')
implementation project(path: ':mobilertc')
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
implementation 'androidx.multidex:multidex:2.0.0'
implementation 'androidx.recyclerview:recyclerview:1.0.0'
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.google.android.material:material:1.0.0-rc01'
}
MainActivity
MainActivity
import androidx.appcompat.app.AppCompatActivity;
import android.content.Intent;
import android.os.Bundle;
import us.zoom.sdk.JoinMeetingOptions;
import us.zoom.sdk.JoinMeetingParams;
import us.zoom.sdk.ZoomSDK;
import us.zoom.sdk.ZoomSDKInitializeListener;
public class MainActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
ZoomSDK sdk = ZoomSDK.getInstance();
MeetingService meetingService = sdk.getMeetingService();
sdk.initialize(this, App_Key, App_Secret, ZoomSDKInitializeListener);
JoinMeetingOptions opts = ZoomMeetingUISettingHelper.getJoinMeetingOptions();
JoinMeetingParams params = new JoinMeetingParams();
params.displayName = displayName;
params.meetingNo = meetingNo;
params.password = meetingPassword;
meetingService.joinMeetingWithParams(context, params, opts);
}
}
推荐答案
建议1:
- 检查导入顺序.
- 在
C:\ Users \< USER> \.gradle \ cache
上清洁gradle缓存 - 在Android Studio中
Invalidate&重新启动
- 哦,是的,发现了问题:(您应该已经完成了建议2)
import com.***.inmeetingfunction.customizedmeetingui.MyMeetingActivity;
import com.***.inmeetingfunction.customizedmeetingui.SimpleZoomUIDelegate;
import com.***.inmeetingfunction.customizedmeetingui.view.MeetingWindowHelper;
import com.***.inmeetingfunction.zoommeetingui.ZoomMeetingUISettingHelper;
此类 ZoomMeetingUISettingHelper
不属于SDK.它是一个自定义类.这就是为什么您不能导入它的原因.只需将其复制到示例中即可.
This class ZoomMeetingUISettingHelper
is not part of the SDK. Its a custom class. That's why you cannot import it. Just copy it over from the sample.
建议2:
与我提到的此处:只需从他们的示例应用程序开始.为什么要尝试重新发明轮子导入库和东西的原因.只需将其现有样本用作起点,然后从那里开始,创建新的活动",视图"等即可.只是不要使用不需要的活动"和视图".完成所有功能后,即可删除并进行一些清理.
Same as I mentioned here: Just start with their sample application. Why you trying to re-invent the wheel importing libraries and stuff. Just use their existing sample as a starting point, and then go from there, create your new Activities, Views etc. Just don't use their Activities and Views you don't need. Once you are done with all the functionality, you can remove and do some cleaning up.
这篇关于无法在我的应用程序中集成缩放的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!