Added set_object method