Can I implement the following method:
// returns weather `v` is instance of `A` def isItOfType[A](v: Any) = ???
With TypeTag? Or do I have to use ClassTag (classsTag[A].runtimeClass.isInstance(v))?
TypeTag
ClassTag
classsTag[A].runtimeClass.isInstance(v)
Aucun commentaire:
Enregistrer un commentaire