Win a copy of Java Concurrency Live Lessons this week in the Threads forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Boolean  RSS feed

 
Bart Wilson
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you have a return type Boolean what does this return, does it returns true/false like the primimtive boolean?
public java.lang.Boolean getIndicator()
{
return mIndicator;
}
 
William Barnes
Ranch Hand
Posts: 1048
2
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It returns a Boolean class. The Boolean class is not the same as the boolean primate. There is a method on the Boolean class which returns true/false.
 
Bart Wilson
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Figured it out the method is booleanValue()
Originally posted by christopher foran:
It returns a Boolean class. The Boolean class is not the same as the boolean primate. There is a method on the Boolean class which returns true/false.

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!