Skip to content

Instantly share code, notes, and snippets.

@daoseng33
Created June 28, 2018 12:56
Show Gist options
  • Save daoseng33/e60ebe0e107a2f51c8c4cb90194ac0ef to your computer and use it in GitHub Desktop.
Save daoseng33/e60ebe0e107a2f51c8c4cb90194ac0ef to your computer and use it in GitHub Desktop.
enum Type {
case regular
case system
case advertise
var image: UIImage? {
switch self {
case .regular:
return UIImage(named: "regular")
case .system:
return UIImage(named: "system")
case .advertise:
return UIImage(named: "advertise")
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment