Rearranged and renamed public API for consistency