Why does java have Type when it already has Object? -
i hoping tell me why java has java.lang.reflect.type
, when inherits object
?
could please give example of case need use type
, not object
?
object
base class java classes. type
tag interface classes represent types. introduced in java 1.5 because prior java 1.5 there no classes represent java type except java.lang.class
. when generics introduced there need create general abstraction common class
, generic array etc. defined interface type
.
Comments
Post a Comment