Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/307.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java IntelliJ Idea没有';不做空检查_Java_Null Check - Fatal编程技术网

Java IntelliJ Idea没有';不做空检查

Java IntelliJ Idea没有';不做空检查,java,null-check,Java,Null Check,我使用java.sql.ResultSet从表的列中检索信息: res.setGatheringInfo(resultSet.getString("MEETUPTIME")); 然后我尝试访问此字段: if (res.getGatheringInfo().equals("CHECK")) { } 为什么Idea不检查res.getGatheringInfo()中可能的空值,并且默认情况下不警告我? 为此,我必须在res.gatheringInfo上设置

我使用java.sql.ResultSet从表的列中检索信息:

res.setGatheringInfo(resultSet.getString("MEETUPTIME"));
然后我尝试访问此字段:

if (res.getGatheringInfo().equals("CHECK")) {
}
为什么Idea不检查res.getGatheringInfo()中可能的空值,并且默认情况下不警告我? 为此,我必须在res.gatheringInfo上设置@Nullable