Learn Java Programming - Instanceof Operator Tutorial

Publicado el: 24 enero 2016
en el canal de: Daniel Ross
1,437
14

The first thing that we need to understand is the definition of a supertype. A supertype is a class or interface that is higher up the inheritance hierarchy. The instanceof operator compares an object(instance) to the Name of a supertype and returns a boolean result. The instanceof operator will also return true if the instance is of the same class name.
(reference variable) instanceof (Name of supertype)
String s = "Hello World";
s instanceof Object; // true


En esta página del sitio puede ver el video en línea Learn Java Programming - Instanceof Operator Tutorial de Duración hora minuto segunda en buena calidad , que subió el usuario Daniel Ross 24 enero 2016, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 1,437 veces y le gustó 14 a los espectadores. Disfruta viendo!