How to import module for Android Studio (for non-gradle)

Source: Internet
Author: User

Similarly, non-gradle compiled works and Gradle compilations also have some differences on the import module . Including the operation, the display of some differences, in the previous article, as long as not labeled "non-gradle" words, are for the use of gradle to build.

Speaking of this, it is estimated that a lot of people will ask, what is the use of gradle to build, how does not count, the difference is very simple, you just see the project root directory, or the module directory there is no build.gradle this file, there is the use of gradle to build, no is non-gradle. (Of course not only this one difference, there are some other documents of the difference, showing the difference, etc., this side does not care).

Well, directly explain how to import module, is a project of mine, will have the unfolded diagram, see the unfolding diagram you will find that the directory structure and Eclipse is basically the same.

For this picture, the next and the project with Gradle build a display difference: Notice a detail, the project's lower right-hand corner of the icon is a small blue box, not like a project using the Gradle build, the lower right corner of the icon is a small blue cup. (In fact, this side of the project itself is being used as a module)


Open the configuration interface via File->project structure, select modules, click +, then select Import Module:


Follow the steps down next, this way only explains one of the steps, see:

Create module from existing sources: When to choose this, if your original sources is not a module, you should choose this, so that Android studio will give you to generate corresponding module matching files.

Import module from external model : If your original sources is a module, then you choose this, such as your original sources was another project when the module was used, you can choose this.

It is estimated that some people will ask, I do not know how to distinguish whether the module, if you can not distinguish between, then you choose the first item by default. Maven here doesn't have to care.


Next, this time, you can see, sources is as a module in the form of guidance, this time, the project has two module.


Let's see, what's changed in project list, see, the original one becomes two, and the imported module and the original module are side-by, and the same way as the two project shown in Eclipse, this is the non-gradle Build and using the Gradle build module display the biggest difference, this time you can also observe the mark, there is no discovery, you import the module in the lower right corner of the icon is not displayed imaging using Gradle build, is a small phone icon, Instead of a small blue box, and in the expanded list, you don't see the Gradle.build file:


How to import module for Android Studio (for non-gradle)

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.