Memory Management

Add deleteAll for cleaning up collection<T*>
Use unique_ptr in a few places.