1 parent fc21337 commit 20501f2Copy full SHA for 20501f2
Design-Patterns.playground/Pages/Behavioral.xcplaygroundpage/Contents.swift
@@ -636,9 +636,9 @@ protocol Garden {
636
extension Garden {
637
638
func prepareGarden() {
639
- func prepareSoil() {}
640
- func plantSeeds() {}
641
- func waterPlants() {}
+ prepareSoil()
+ plantSeeds()
+ waterPlants()
642
}
643
644
@@ -649,15 +649,15 @@ final class RoseGarden: Garden {
649
650
651
func prepareSoil() {
652
- // Implementation
+ print("prepareSoil for Rose Garden")
653
654
655
func plantSeeds() {
656
+ print("Plant Seeds for Rose Garden")
657
658
659
func waterPlants() {
660
+ print("Water the Rose Garden")
661
662
663
0 commit comments