简体   繁体   中英

Eclipse doesn't identify my project as Java

I import a project from the SVN, which is a Java project.

When I open one of it class, for example, I can't use open declaration\\open implementation\\ open return type, and so on..

It just show me the class as a text file. How can I fix it?

Go to project->properties->facets->java and enable the java facet

Alternatively you can open the .project file and add the java nature eclipse is adding for new java projects:

<projectDescription>
    <buildSpec>
        <buildCommand>
            <name>org.eclipse.jdt.core.javabuilder</name>
            <arguments>
            </arguments>
        </buildCommand>
    </buildSpec>
    <natures>
        <nature>org.eclipse.jdt.core.javanature</nature>
    </natures>
</projectDescription>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM