mirror of
https://github.com/tmrts/go-patterns.git
synced 2024-11-25 06:26:06 +03:00
Replace non-existing method Paint with Color
This commit is contained in:
parent
f978e42036
commit
00ebbdb97d
@ -51,7 +51,7 @@ type Interface interface {
|
|||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
```go
|
```go
|
||||||
assembly := car.NewBuilder().Paint(car.RedColor)
|
assembly := car.NewBuilder().Color(car.RedColor)
|
||||||
|
|
||||||
familyCar := assembly.Wheels(car.SportsWheels).TopSpeed(50 * car.MPH).Build()
|
familyCar := assembly.Wheels(car.SportsWheels).TopSpeed(50 * car.MPH).Build()
|
||||||
familyCar.Drive()
|
familyCar.Drive()
|
||||||
|
Loading…
Reference in New Issue
Block a user