Move lots of methods to use the util classes.

Clean up tests.