Reorganized to keep implementations together for now.