title: Struggle to read csv file
body: <p>I am struggling to figure out how i can work with CSV files in scala. I have this code and i have tried to implement various types of codes for csv reading etc, but not been able to actually read a file at all. the // read file is me trying / my late4st attempemt but i get an : object Source is not a member of package org.apache.http.io
  [error]     val filename = io.Source.fromFile(&quot;countries.csv&quot;)</p>
  <p>Cn someone help me out what am i doing wrong ?</p>
  <pre><code>import java.io._
  import org.apache.commons._
  import org.apache.http._
  import org.apache.http.client._
  import org.apache.http.client.methods.HttpPost
  import org.apache.http.impl.client.DefaultHttpClient
  import java.util.ArrayList
  import org.apache.http.message.BasicNameValuePair
  import org.apache.http.client.entity.UrlEncodedFormEntity
  import com.google.gson.Gson
  import scala.io.Source
  
  case class Teacher(firstName: String, lastName: String, age: Int)
  //case class Country(name: String, region: String, population: Int, area: Int, popDensity: Int, coastline: Int, netmigration: Int, infantMortality: Int, gdp: Int, literacy: Int, phones: Int, arable: Int, crops: Int, other: Int, climate: Int, birthrate: Int,deathrate: Int, agriculture: Int, industry: Int, service: Int)
  
  object HttpJsonPostTest extends App {
      //read data 
      val filename = io.Source.fromFile(&quot;countries.csv&quot;)
      for(line &lt;- filename.getLines){
          val col = line.split(&quot;,&quot;).map(_.trim)
          println(s&quot;${cols(0)}|${cols(1)}|${cols(2)}|${cols(3)}&quot;)
      }
  
  
  
      // create our object as a json string
      val marius = new Teacher(&quot;Lucas&quot;, &quot;Geitle&quot;, 32)
      val mariusAsJson = new Gson().toJson(marius)
  
      // add name value pairs to a post object
      val post = new HttpPost(&quot;http://127.0.0.1:2379/v2/keys/big_data_course1&quot;)
      val nameValuePairs = new ArrayList[NameValuePair]()
      nameValuePairs.add(new BasicNameValuePair(&quot;value&quot;, mariusAsJson))
      post.setEntity(new UrlEncodedFormEntity(nameValuePairs))
  
      // send the post request
      val client = new DefaultHttpClient
      val response = client.execute(post)
      println(&quot;--- HEADERS ---&quot;)
      response.getAllHeaders.foreach(arg =&gt; println(arg))
  }
  </code></pre>