Top "Instanceof" questions

instanceof is an operator available in some object-oriented languages, including Java, php and JavaScript.

OCaml: Type Checking Objects

If I have an object, how can I determine its type? (Is there an OCaml equivalent to Java's instanceof operator?)

object ocaml instanceof typechecking
What does this instanceof error message mean?

I was playing around with instanceof in Chrome but I got an error message. I think I know why (you …

javascript instanceof
Javascript inheritance - instanceof not working?

I'm writing a simple platform game using javascript and html5. I'm using javascript in an OO manner. To get inheritance …

javascript oop inheritance instanceof
Java instanceof with class name

I am just curious to ask this, maybe it is quite meaningless. When we are using instanceof in java, like: …

java class instanceof
What is the VB equivalent of Java's instanceof and isInstance()?

In the spirit of the c# question.. What is the equivalent statements to compare class types in VB.NET?

java vb.net reflection introspection instanceof
What's the difference between isPrototypeOf and instanceof in Javascript?

In some of my own older code, I use the following: Object.prototype.instanceOf = function( iface ) { return iface.prototype.isPrototypeOf( …

javascript inheritance prototype instanceof
Switch by class (instanceof) in PHP

It is possible to replace block of if( .. instanceof ...), elseif(... instanceof ...), ... with switch? For example: <?php $class = ..... //some class …

php switch-statement instanceof
instanceof negation

Which is the correct format for negating instanceof? if ( ! $a instanceof stdClass) or if ( ! ($a instanceof stdClass) ) I've convinced myself …

php instanceof
Java instanceof with changing objects

I need a method where i could pass on a parameter which i assume would be a Class (not sure …

java dynamic instanceof
instanceof keyword usage

Is using the instanceof keyword against the essence of object oriented programming? I mean is it a bad programming practice? …

java instanceof