Yuta chiharu
β
Factory method
yes ...i think we use factory for loose coupling and many more things
example
if you create the object directly and now you need to change your
car
to raceCar
we cant do that but with factory we can acheive that by simply changing the return new Car()
to return new raceCar()
if any wrong someone teach me tooπ
5 replies