Add closure design pattern