Problems working with ormlite using IntelliJ on Mac OSX

我是研究僧i 提交于 2019-12-10 22:31:40

问题


I am developing an Android application with a sqlite database in an Ubuntu loaded notebook on Intellij IDEA and using database mapping using ormlite. I installed ormlite-android-4.23.jar, ormlite-core-4-1.31.jar, and ormlite-4.23.jar in libs directory of the project folder. I was not sure which version is used here. The application was running and I tried to use my Macbook to proceed with my app development. I am new to Macbook. It is loaded with Mac OS X version 10.5.8. The app is not running.

The following are indicated in red by Intellij and its message is:

cannot resolve

j256 in import com.j256.ormlite.android.apptools.OrmLiteBaseActivity, and other places related ormlite.

I am new to developing this kind of applications and can anybody help me? I noted in a similar question the answer was downloading ormlite version 4.20. I need to know exactly the name of file and where should be saved this.


回答1:


Most likely you need 2 files:

  • ormlite-core-4.33.jar
  • ormlite-android-4.33.jar

Place these files in any directory of your project (while libs is designed for native .so libraries, many developers use it for jar libraries so you can use it). Then configure a library in IntelliJ IDEA and add it to the dependencies of your module.




回答2:


You also can add it to your dependencies:

compile group: 'com.j256.ormlite', name: 'ormlite-core', version: '4.33'
compile group: 'com.j256.ormlite', name: 'ormlite-android', version: '4.33'


来源:https://stackoverflow.com/questions/9107947/problems-working-with-ormlite-using-intellij-on-mac-osx

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