티스토리 뷰

728x90
value = value.getClass().cast(val);

https://stackoverflow.com/questions/3939054/dynamic-casting-in-java

 

Dynamic casting in Java

Before I get chided for not doing my homework, I've been unable to find any clues on the multitude of questions on Java generics and dynamic casting. The type Scalar is defined as follows: public...

stackoverflow.com

 

728x90
댓글