Added hierarchical design pattern