I have been looking for Strategy Pattern and I saw This link which the guy has explained this pattern very well.
But as far as I know (maybe right or wrong) you shouldn't make a new class in another class (for the sake of being loosely coupled).
this.motor = new Motor(this)
Is there a better kind of implementation for that to not violate the principles (like IoC)?