Androidstuido How to join a third party open source class library.

Source: Internet
Author: User

Androidstudio more and more people are using it, here's how Androidstudio joins third-party open-source class libraries like eclipse:

1. If the Open Source Library is hosted on GitHub, then you can directly join the Open source class library, but the individual does not recommend this, because in this case, the source code of the library is not convenient, Enter your project edit Build.gradle directory, add the introduction library description in dependencies, how to:


Add a diagram after the introduction of the library:


You need to introduce which library to go to the repository of GitHub's managed address of the including into your project directory under the code, and add it up.


2. The second method is to download the remote repository and put it on.

Download the open Source Library, place it in the same directory as the app directory, and edit the Setting.gradle ": Open Source Library folder name". For example, I placed the volley Open Source Library folder in the app's sibling directory, and then edited the Setting.gradle and changed the contents to:

1 include ‘:app‘, ‘:volley‘

Then go back to the Build.gradle file in your app directory and add it under the dependencies {} node:

1 compile project(‘:volley‘)

This makes it possible to reference the local open Source library.






Androidstuido How to join a third party open source class library.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.