Differences among various bool types?
boolean
is a java primitive type. It only accepts true
or false
(which are declared constants in java).
Boolean is a Serializable wrapper of boolean
primitive type. From the JDK....
The
Boolean
class wraps a value of the primitive type boolean in an object. An object of type Boolean contains a single field whose type isboolean
.
bool
doesn't exist in java, but it does in Android as R.bool
.
bool
does not seem to exist, at least I can't find references to it.
boolean
is a primitive boolean type, not an object.
Boolean
is the wrapper object for a boolean
.