Closed leandromsales closed 10 years ago
I can’t wait for that! Feel free to do it. I’m looking forward for your PR.
Thank you V.
Hi Vinnylinck, I have finishd the basic implementation, although there are some improvements to be developed. I'm getting in touch because I need some help, maybe you can help me. I forked your project [1] and the current problem that I'm facing is when I try to export the functions (file src/blackberry10/index.js). I tried may different options/configuration in the plugin.xml to make cordova recognize the functions to be called when your plugin call cordova.exec, but any tentative worked.
Basically, in the src/blackberry10/index.js file I put only (for now) two method: connect and other open named ping (for testing purpose). The index.js.bk file is another version of something that I was trying to do. The current index.js is just something that I did to see if cordova is able to call the methods, what is not working. I see in your cordova.exec that you used _ID as Socket. I'm not so expert in Cordova Plugin development, so I'd like to know what exactly I have to do in the index.js to properly export the plugin function (connect, disconnect, disconnectAll etc.), because the way that I'm doing is not working (please check the code). Should I export my functions using module.exports and make a specific setup in the plugins.xml? I saw in the WP8 plugin that they use a commandProxy to determina what structure will handle the cordova.exec calls, but in the case of BlackBerry I did not find anything similar. Although I'm doing module.exports, nothing is merge in com.tlantic.plugins.socket.Socket. I saw in WP8 plugin that they export "Socket" to be the structure they defined containing the plugin functions that handles the cordova.exec, but I don't know how to do that since there is no mechanism for proxy, like WP API provides. I read so many docs about cordova plugin api, but in certain moment I got lost with so many concepts and tentatives.
Anyway, the easiest part for me was to develop the native code. I had som experience developing others plugin for BlackBerry in Cordova, but for this one, there is something that I don't know what to do. Can you please try to help me? in src/blackberry10/ there other two .js files that I implemented when I was trying to do something different.
Thank you.
Hi @leandroal
Should I export my functions using module.exports and make a specific setup in the plugins.xml? Yes you should, you really need to expose it.
Please, try to see how the others are linked, I will check your implementation and let you know.
Hi, Probably I found the solution. As soon as I get progress I get back to you. Thanks,Leandro. Sent from my BlackBerry 10 smartphone. From: KautzmannSent: segunda-feira, 20 de outubro de 2014 10:08To: Tlantic/cdv-socket-pluginReply To: Tlantic/cdv-socket-pluginCc: Leandro Melo de SalesSubject: Re: [cdv-socket-plugin] Add Support for BlackBerry 10 (#60)Hi @leandroal
Should I export my functions using module.exports and make a specific setup in the plugins.xml? Yes you should, you really need to expose it.
Please, try to see how the others are linked, I will check your implementation and let you know.
—Reply to this email directly or view it on GitHub. {"@context":"http://schema.org","@type":"EmailMessage","description":"View this Issue on GitHub","action":{"@type":"ViewAction","url":"https://github.com/Tlantic/cdv-socket-plugin/issues/60#issuecomment-59737007","name":"View Issue"}}
Yeah right, I will close this. Let us know if we can help on something. Feel free to raise Issues and PR.
Hi Vinny and Felipe, I'm the coordinator of the BlackBerry Tech Center Brazil and I'm developing the support of BlackBerry 10 socket into your plugin and I wish to send you a pull request when I finish it. Do you have interest on that?
Thank, Leandro.