相关疑难解决方法(0)

java.lang.NoClassDefFoundError:解析失败:Landroid/webkit/SafeBrowsingResponse

我正面临这个例外

"java.lang.NoClassDefFoundError:解析:Landroid/webkit/SafeBrowsingResponse失败",同时在android中实现webview.

我已经在网上搜索了一个合适的解决方案,但没有找到任何有用的解决方案.

我的XML文件是这样的

    <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical">

        <include layout="@layout/toolbar_title" />


        <im.delight.android.webview.AdvancedWebView
            android:id="@+id/mWebview"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </LinearLayout>

</RelativeLayout>
Run Code Online (Sandbox Code Playgroud)

我对这个XML的java代码是

public class PaymentActivity extends ParentActivity implements AdvancedWebView.Listener {

//    private WebView webView;

private AdvancedWebView mWebView;
ProgressDialog dialog;
UserModel userModel;
SessionManager sessionManager;

@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_payment);

    ButterKnife.bind(this);
    setActionBar("Payment");
    sessionManager = new SessionManager(this);
    userModel = sessionManager.getUserInformation();

    mWebView = findViewById(R.id.mWebview);
    mWebView.setListener(this, this);
    mWebView.getSettings().setJavaScriptEnabled(true);


    String planType = getIntent().getStringExtra("planType");

    String url = …
Run Code Online (Sandbox Code Playgroud)

java android webview android-layout

6
推荐指数
1
解决办法
5428
查看次数

标签 统计

android ×1

android-layout ×1

java ×1

webview ×1