I have a simple method in scala which requires type information of parameters at runtime, thus I am using ClassTag
, but I want my method to be inter operable with java. But ClassTag
s are not java friendly. So is there a workaround to make it work with Java?
Minimalistic method signature:
def myMethod[T : ClassTag](x: T): Unit = {
Thanks
Aucun commentaire:
Enregistrer un commentaire