design pattern study