What is the instanceof operator used for? I\'ve seen stuff like
instanceof
if (source instanceof Button) { //... } else { //... }
If source is an object variable, instanceof is a way of checking to see if it is a Button or not.
source
object
Button