不使用吧code扫描仪的应用程序嵌入Zxing库扫描仪、应用程序、code、Zxing

2023-09-11 11:38:01 作者:不該去說從前

什么是preferred方式嵌入zxing库来提供扫描,而无需安装吧code扫描仪的应用程序?我期待将它嵌入在Android中,而无需提示用户任何额外的安装。 (类似iPhone SRC的工作方式)。

What is the preferred way to embed the zxing library to provide scanning without having the Barcode Scanner app installed? I am looking to embed it in android without having to prompt the user for any extra installs. (Similar to the way the iPhone src works).

推荐答案

这真的很容易,只需通过整合意图。更可靠,并且可以自动获得更新。虽然我不建议这...

It's really easier to just integrate via Intent. More reliable, and you get updates automatically. While I don't advise it...

完整的源$ C ​​$ c是可从 ZXing 项目。你想打造 core.jar添加核心/ 键,把它放在你的Andr​​oid 的lib / 文件夹,包括核心去codeR在你的应用程序。你不希望包括 JavaSE的。你可以看一下code。在安卓/ ,因为它是吧code扫描仪的来源,但作为作者,我们建议你不只是复制并粘贴。

The complete source code is available from the ZXing project. You want to build core.jar from core/ and put it in your Android lib/ folder to include the core decoder in your app. You do not want to include javase. You can look to the code in android/ as it is the source to Barcode Scanner, but as the authors we'd suggest you not just copy and paste it.

有的Apache许可这意味着你可以用它自由,只要你基本上是给用户访问许可条款。

It is Apache licensed which means you can use it freely, as long as you essentially give the user access to the license terms.