blob: 006c2e3407ecfebce60dd2dc4f8e092e3d98b3de [file] [log] [blame]
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
class Doo {
@NotNull
public String doSomething() {
String s = getSomeString();
if (s == null) {
throwSomeError();
}
return s;
}
private static void throwSomeError() {
throw new RuntimeException();
}
@Nullable
public String getSomeString() {
return Math.random() > 0.5 ? null : "Yeah";
}
}