What is the colon in the type parameter of a scala class
class, generics, scala
Solution
This is a syntactic variant for writing
abstract class RDD[T](implicit context: ClassTag[T])
The comments to this question already link to two related questions that explain what this so-called 'context bound' is about.
Problem
I know when a class is parameterized, it could be declared as ``` class A[T] ``` I see declaration of RDD of Spark begins with: ``` abstract class RDD[T: ClassTag] ``` I don't know what does the `: ClassTag` mean.