Java 如何在新的webview窗口中打开扫描的链接AndroidStudio Zxing

Java 如何在新的webview窗口中打开扫描的链接AndroidStudio Zxing,java,android,sdk,Java,Android,Sdk,我有一个条形码扫描仪应用程序, 我不能那样做 所以在我扫描QRcode(其中有一个链接)之后, 这样他就可以在新的webview活动中打开它, 或者在弹出式活动中 我请求帮助,我是初学者 在android studio java中 import android.app.Activity; import android.content.Intent; import android.support.v7.app.AppCompatActivity; import android.os.Bundle;

我有一个条形码扫描仪应用程序, 我不能那样做 所以在我扫描QRcode(其中有一个链接)之后, 这样他就可以在新的webview活动中打开它, 或者在弹出式活动中

我请求帮助,我是初学者 在android studio java中

import android.app.Activity;
import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
import com.google.zxing.integration.android.IntentIntegrator;
import com.google.zxing.integration.android.IntentResult;

public class ReaderActivity extends AppCompatActivity {
private Button scan_btn;
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_reader);
    scan_btn = (Button) findViewById(R.id.scan_btn);
    final Activity activity = this;
    scan_btn.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View view) {
            IntentIntegrator integrator = new IntentIntegrator(activity);

 integrator.setDesiredBarcodeFormats(IntentIntegrator.DATA_MATRIX_TYPES);
            integrator.setPrompt("Scan");
            integrator.setCameraId(0);
            integrator.setBeepEnabled(false);
            integrator.setBarcodeImageEnabled(false);
            integrator.initiateScan();
        }
    });
}

 @Override
 protected void onActivityResult(int requestCode, int resultCode, Intent     
 data) {
    IntentResult result = 
 IntentIntegrator.parseActivityResult(requestCode, resultCode, data);
    if(result != null){
        if(result.getContents()==null){
            Toast.makeText(this, "You cancelled the scanning", 
  Toast.LENGTH_LONG).show();
        }
        else {
            Toast.makeText(this, 
 result.getContents(),Toast.LENGTH_LONG).show();


          }
        }
        else {
            super.onActivityResult(requestCode, resultCode, data);
        }
    }
}

如果需要加载链接,请创建webView活动,然后使用
putExtras
getExras
然后在同一活动中加载webview