Rearranges structure to allow for a public API