Switch Batch to an implementation of Engine.

This is in preparation of Pete's proposed change to move Batch and
Snapshot into C++.