Add member to write multiple objects to file