Factored out OAI-PMH formatter.