问题
I'd like to make an android application with in app purchases.
So I read some document and knew that I have to download the Google Play Billing Library from SDK Manager.
But I can't find that library in my Android Studio SDK Manager.
I tried to add compile 'com.android.billingclient:billing:1.0'
to the dependencies section of the build.gradle file for my app.
But I can't still find the library..
How can I solve my problem?
回答1:
It looks like you have to add it to your build.gradle dependencies, have a look at these docs. So it won't appear in the SDK manager. Once you've added the dependency in build.gradle, you'll need to create a billing library client, as per the code in the example in the docs.
Or, have a look at the billing example provided by Google.
回答2:
here:https://github.com/bumptech/glide/issues/2993
Solved by re-order repositories from
repositories {
google()
jcenter()
mavenCentral()
}
To
repositories {
mavenCentral()
google()
jcenter()
}
来源:https://stackoverflow.com/questions/48831282/i-cant-find-google-play-billing-library-in-the-android-studio-sdk-manager