Error with parsing Android sdk content and initializing java tooling in eclipse

前端 未结 16 1915
时光取名叫无心
时光取名叫无心 2021-02-13 15:19

Every time I open Eclipse, I get the following error messages:

Android SDK Content Loader: parseSdkContent failed java.lang.NullPointerException

Initializing Jav

相关标签:
16条回答
  • 2021-02-13 15:45

    Your answers might be right. What I did was to change my workspace. I redownloaded the project I was going to work on from git, and reimported it. Now it works fine :) Maybe there was some files in this project that made the error messages apear? Dunno....

    0 讨论(0)
  • 2021-02-13 15:45

    I discovered another cause, where I'd added a space character into an otherwise blank line in the project.properties file. When I eventually ran android update project -p . the program (android.exe) threw a NPE exception. When I deleted the space from the blank line the android update project command worked and eclipse started behaving (after running clean a few times).

    This happened with r20 of the Android SDK on a Windows 7 64-bit machine.

    FYI my change that fixed the problem in project.properties is public at http://code.google.com/p/android-daisy-epub-reader/source/detail?r=517

    0 讨论(0)
  • 2021-02-13 15:52

    I hope this is useful to someone and saves his/her time: My colleague was facing same issue and we did almost everything mentioned here, with no luck. In the end we changed the Android SDK version in the manifest file and it worked.

    0 讨论(0)
  • 2021-02-13 15:53

    I have remove the .metadata folder but after it, when I run the eclipse, I cannot creates any Android project. To solve it, I have done the follow:

    1. Go to the main work directory of eclipse
    2. Localize the folder com.android.ide.eclipse.adt It should be in .oldMetadata/.plugins/
    3. Copy it to the new eclipse configuration: .metadata/plugins/

    See the full solution here: http://www.jiahaoliuliu.com/2011/06/running-android-sdk-in-eclipse-errors.html#solution4

    0 讨论(0)
  • 2021-02-13 15:54

    If you are using SVN or GIT please check whether the project.properties has conflicts or not. Sometimes project can not be open because of this.

    0 讨论(0)
  • 2021-02-13 15:57

    I encountered exactly the same issue this morning. This is a workspace related issue.

    Solution 1
    I looked into my .metadata and read .bak_number.log files . Some layouts failed to parse and my projects were out of sync with the file system. So I deleted all the .bak_number.log files. Relaunch Eclipse and the whole worskspace should work again the way you left previously.

    Solution 2
    However if it's not due to out of sync with the file system. Change the workspace then import all the eclipse projects from the previous workspace. Thanks the project.properties files , the dependencies are still kept.

    PS : I should return to IntelliJ :)

    0 讨论(0)
提交回复
热议问题