title: Passing Scala Class as parameter?
body: <p>I'm looking to pass a Class as a parameter to a Scala function like so:</p>
  
  <pre><code>def sampleFunc (c : Class) : List[Any]  
  </code></pre>
  
  <p>(Side question: should the type in the parameter be Class or Class[_]?)</p>
  
  <p>The reason I'm passing a Class type is to check whether an object belongs to a particular type or not. At the moment, as a workaround, I'm passing a sample object to the method and comparing the two object's .getClass result. I hardly think this is ideal though and I'm sure there's a clearly defined way of passing Types in Scala.</p>