mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-10 18:09:38 +07:00
16 lines
497 B
Java
16 lines
497 B
Java
import org.jetbrains.annotations.NotNull;
|
|
import org.jetbrains.annotations.Nullable;
|
|
|
|
import java.util.Collection;
|
|
|
|
class Bar3 {
|
|
|
|
public void foo(@Nullable Object element) {
|
|
final String elementType = element != null ? element.toString() : null;
|
|
if (elementType == nullableString()) {
|
|
System.out.println(element.<warning descr="Method invocation 'hashCode' may produce 'NullPointerException'">hashCode</warning>());
|
|
}
|
|
}
|
|
|
|
@Nullable String nullableString() { return null; }
|
|
} |