본문 바로가기

JAVA

[JAVA] Convert Object to Boolean. Object - Boolean 형변환

 

 

1.

 

((Boolean) Object).booleanValue();

 

 

2. 

 

boolean bl = (Boolean) Object;

 

 

3.

 

boolean bl = Boolean.valueOf(Object.toString())