implementing of band of four's design patterns