Yes you can use Boolean
/boolean
instead.
First one is Object and second one is primitive type.
-
On first one, you will get more methods which will be useful.
-
Second one is cheap considering memory expense The second will save you a lot more memory, so go for it
Now choose your way.