/// <summary> /// Fix up the reading collection from the given DTOs /// </summary> /// <param name="readingCollectionDto">Reading DTO collection</param> internal void FixupFromDto(ReadingCollectionDto readingCollectionDto) { this.dao = readingCollectionDto.Dao; foreach (ReadingDto readingDto in readingCollectionDto) { Reading newReading = new Reading(); newReading.FixupFromDto(readingDto); this.readings.Add(newReading); } }
/// <summary> /// Create the accumulated readings collection in the database /// </summary> public void Create() { this.dao = new BinaryFileReadingCollectionDao((BinaryFileArchiveDao)this.archive.Dao); this.dao.Create(CreateDto()); }