i have a code as
public class BooleanTest {
public BooleanTest() {
super();
}
public static void main(String args[]){
BooleanTest bt = new BooleanTest();
bt.doProcess();
}
private boolean method() {
return false;
}
private void doProcess() {
Boolean obj = (Boolean)method();
System.out.println(obj.booleanValue());
}
}
the question is can line System.out.println(obj.booleanValue());
throw NullPointerException
in any situation?