简体   繁体   English

将.jar SDK添加到Cordova Hybrid app Visual Studio

[英]Add .jar SDK to Cordova Hybrid app Visual Studio

I'm trying to implement an SDK for my Handheld API to an Cordova Hybrid App in Visual Studio. 我正在尝试为Visual Studio中的Cordova Hybrid App的Handheld API实现SDK。 It's a .jar File. 这是一个.jar文件。 I'm new in Cordova/PhoneGap developing, so I just want to know if its possible to generate the Bindings API/Wrapper automatically like in Xamarin with " Bindings Library(Android) ". 我是Cordova / PhoneGap开发的新手,所以我只想知道是否有可能像Xamarin中的“ Bindings Library(Android) ”一样自动生成Bindings API / Wrapper。

so I just want to know if its possible to generate the Bindings API/Wrapper automatically like in Xamarin with "Bindings Library(Android)". 所以我只想知道是否有可能像在Xamarin中使用“ Bindings Library(Android)”那样自动生成Bindings API /包装器。

As far as I know, there is no way to generate the Bindings API/Wrapper automatically. 据我所知,没有办法自动生成Bindings API / Wrapper。 If you want to call the APIs in your .jar file, you can use the Ace Plugin to invoke the native codes. 如果要在.jar文件中调用API,则可以使用Ace插件来调用本机代码。

Or you can write a plugin that reference this framework(using <lib-file /> tag in Plugin.xml ), and wrap the API manually with JS code. 或者,您可以编写一个引用此框架的插件(使用Plugin.xml <lib-file />标记),然后使用JS代码手动包装API。

For details about creating an Android Plugin, please refer to Android Plugin Development Guide . 有关创建Android插件的详细信息,请参阅《 Android插件开发指南》

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM