Reputation: 685
I'm binding Stripe's android library in Xamarin.Android. I succeeded in creating the binding project and building it finally after a lot of error resolutions. Now, when I want to use the library I finally built in my project, I get this error without any additional information:
Java.Lang.NoClassDefFoundError: 'Failed resolution of: [Lkotlin/reflect/KProperty;'
I added the .aar library in my android project and set the build property to Androidaarlibrary, and referenced the binding project directly from the .dll created, but nothing worked. I tried everything I could find but nothing worked.
I have added the dependencies found in the kotlin library, as you can see below:
Here is what I added as dependencies in the xamarin binding project:
I really don't know what else to try, can someone help please ?
Upvotes: 0
Views: 1335
Reputation: 894
The NAXAM's binding project mentioned in the last answer is outdated. I'm in the same situation, so I've tried to do my own binding and after two weeks of work resolving binding errors (both compile and run time) I finally gave up on that approach.
Now we are using the http API from stripe, and making some calls directly from the server, because you cannot authenticate against the stripe service from the client, specially if you need to comply with SCA and 3DSecure and all that new stuff.
So my recommendation will be to use the API as it is instructed here: https://stripe.com/docs/api
PRO tip (kind of...): You can still use the old bindings to implement the nice views that Stripe is provinding to enter the card information and to do the client verification of the entered number.
PRO tip 2: There is a channel where the Stripe employees will answer and help you with any doubt, they really know their jobs, are willing to help everybody and there is always someone answering your questions (This channel was a treasure really hard to find): https://freenode.logbot.info/stripe
Upvotes: 0
Reputation: 1007
if you bind .aar or .jar file contain kotlin source code, you need install Xamarin.Kotlin.StdLib
on your xamarin project via nuget
, plz install this Link on your project and then build your project, maybe this way work for you.
even you can send your .aar file to my email address, and i can bind for you, or test .dll file on my project.
Upvotes: 2
Reputation: 18861
It seems that you want to use the Stripe payment platform , right ? Fortunately ,it is available in nuget . You could check from the Github Project Site . And you could refer the demo from https://github.com/NAXAM/stripe-android-binding/tree/master/Demo .
Upvotes: 0