Continued improvements for Class/BatchClass creation.

Almost all integration tests pass.