怎么这么红?IntelliJ 似乎认为每个声明/方法都无法找到/解决 [英] Why so red? IntelliJ seems to think every declaration/method cannot be found/resolved

查看:17
本文介绍了怎么这么红?IntelliJ 似乎认为每个声明/方法都无法找到/解决的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚安装并重新安装了 IntelliJ.每个 Java 文件都将变为 RED.我检查了JDK;它是 1.6.##.maven clean install 构建运行得很好.

I just installed and re-installed IntelliJ. Every Java file is coming up RED. I checked the JDK; it is at 1.6.##. The maven clean install build worked just fine.

我收到了通常突出显示的错误.在每个声明上:

I'm getting the usual highlighted errors. On every declaration:

无法解析符号 SomeEntityBean/Bean

Cannot resolve symbol SomeEntityBean/Bean

以及每种方法:

无法解析方法 SomeFunction()

Cannot resolve method SomeFunction()

我该如何修正这些错误的错误?

How do I fix these false errors?

推荐答案

即使没有 Korgen 描述的外部更改,IntelliJ 有时也会被自己弄糊涂(尽管这是一致重现它的好方法).

IntelliJ sometimes gets confused all by itself, even without the external changes Korgen described (though that is a good way to consistently reproduce it).

单击文件 -> 同步,IntelliJ 应该会再次看到一切正常.

Click File -> Synchronize, and IntelliJ should see that everything is okay again.

如果这不起作用,则 IntelliJ 的缓存可能已损坏(过去这种情况比现在更频繁);在这种情况下,通过

If that doesn't work, IntelliJ's caches might be corrupt (this used to happen a lot more often than it does now); in that case, regenerate them by

单击文件 -> 使缓存无效并重新启动 IDE

(尽管在重新创建缓存时加载项目需要一段时间).

(though loading the project will take a while while the caches are recreated).

这篇关于怎么这么红?IntelliJ 似乎认为每个声明/方法都无法找到/解决的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆