How do you check if an object is of a certain type Java?

The java “instanceof” operator is used to test whether the object is an instance of the specified type (class or subclass or interface). It is also known as type comparison operator because it compares the instance with type. It returns either true or false.

Sizin İçin Seçtik  Avrupa piyasaları kaçta açılıyor?

Leave a Reply

Your email address will not be published. Required fields are marked *