scala/scala — pull request #3857 by jxcoder (2014-07-02 08:43:39+00:00)
Title: Added example to Option.collect method.

I added code which described how to **Option.collect** method works.
```scala
// Returns Some(HTTP) because the partial function covers the case.
Some("http").collect({case "http" => "HTTP"})

// Returns None because the partial function doesn't cover the case.
Some("ftp").collect({case "http" => "HTTP"})

// Returns None because None is passed to the collect method.
None.collect({case value => value})
```