I\'m going through a book on data structures. Currently I\'m on graphs, and the below code is for the vertex part of the graph.
class Vertex{ /
It's because this method existed before generics, so for backward compatabitity it has to stay this way.
The standard workaround to impose type is:
return obj instanceof MyClass && ;