SPARK-1767: Prefer HDFS-cached replicas when scheduling data-local tasks

This change reorders the replicas returned by
HadoopRDD#getPreferredLocations so that replicas cached by HDFS are at
the start of the list.  This requires Hadoop 2.5 or higher; previous
versions of Hadoop do not expose the information needed to determine
whether a replica is cached.
I can't think of a better name here.  "ClassesAndMethods" seems too cumbersome.

In my mind, at least, "Hadoop2Classes" immediately makes it clear what is going on.  Plus, classes are really not of much use without methods.  We don't say "please implement a Foo class and Foo methods", we just say "please implement a Foo class".  The methods are assumed to be part of the class, just as they are here.

I'm open to suggestions, though...