Only used when debugging, and in that case, the functionality could be implemented using private APIs.