Refactor for more generic structure. (0.1.1)