What do i need to do after importing aar with File|New|NewModule?

不想你离开。 提交于 2019-12-25 06:07:24

问题


I am trying to use the library android-simple-storage from github. Most of the questions about aar files are for AS previous to 1.3 and do not answer this specific question. I downloaded the zip file, unzipped it, and built it with Android Studio. I found the library-release.aar file in library/build/outputs/aar, renamed it to AndroidSimpleStorage.aar, then imported it into my project using File|New|NewModule.

The problem is that i get "cannot resolve symbol" errors for Storage and SimpleStorage in statements such as these two:

static Storage storage = null;

storage = SimpleStorage.getExternalStorage();

The author has these import statements which work in his test code, but when i use them i get "cannot resolve symbol" for sromku:

import com.sromku.simple.storage.SimpleStorage;
import com.sromku.simple.storage.SimpleStorageConfiguration;
import com.sromku.simple.storage.Storage;
import com.sromku.simple.storage.helpers.OrderType;

So there is something am missing? Any help appreciated.


回答1:


Also, don't forget to compile it into your gradle settings.

You can do this by opening project settings and adding the new module to your app's dependencies tab.



来源:https://stackoverflow.com/questions/32598247/what-do-i-need-to-do-after-importing-aar-with-filenewnewmodule

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!