scala/scala — pull request #3862 by jxcoder (2014-07-03 04:05:50+00:00)
Title: Refactored example to Option.collect method.

After refactoring:
```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}
```