data struct refactor