some design patterns