Refactor register* methods into ImageDatabase.