Skip to content

Instantly share code, notes, and snippets.

@fishmacs
Created January 5, 2013 15:05
Show Gist options
  • Save fishmacs/4462013 to your computer and use it in GitHub Desktop.
Save fishmacs/4462013 to your computer and use it in GitHub Desktop.
scala tips 1
if oName.isDefined oName.get.toUpperCase else "Name not present"
oName.map(_.toUppercase).getOrElse("Name not presented")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment