class Map {
let type : Int = 0
func showMap…
should be:
class Map {
let type: Int = 0
func makeMap…
and then:
let map = Map()
map.makeMap(type: Maps.google).showMap()
map.makeMap(type: Maps.apple).showMap()
will show:
showing google map
showing apple map
[…] Click here to read more. […]
class Map {
let type : Int = 0
func showMap…
should be:
class Map {
let type: Int = 0
func makeMap…
and then:
let map = Map()
map.makeMap(type: Maps.google).showMap()
map.makeMap(type: Maps.apple).showMap()
will show:
showing google map
showing apple map
Why would you suggest that ?