Skip to main content

instanceof is an operator available in some object-oriented languages, including Java, php and JavaScript. Generally speaking, it allows the programmer to check whether an object passed as its left operand is an instance of a class specified by the right operand.

instanceof is an operator available in some object-oriented languages, including Java, php and JavaScript. It allows the programmer to check whether an object passed as its left operand is an instance of a class specified by the right operand.

instanceof in Java

instanceof in php

instanceof in JavaScript