예제 #1
0
        public bool UpdatePartEntity(IVfPartModel model, VfSpeaker.Data.DataStore.VfPartRow row)
        {
            row.Text = model.Text;
            row.DocumentId = model.DocumentId;
            row.Processed = model.Processed;

            return true;
        }
예제 #2
0
 public IVfPartModel BuildPartModel(VfSpeaker.Data.DataStore.VfPartRow row)
 {
     return new VfPartModel()
     {
         Id = row.Id,
         Text = row.Text,
         DocumentId = row.DocumentId,
         Processed = row.Processed
     };
 }
예제 #3
0
        /// <summary>
        /// Updates the document entity.
        /// </summary>
        /// <param name="model">The model.</param>
        /// <param name="row">The row.</param>
        /// <returns><c>true</c> if XXXX, <c>false</c> otherwise</returns>
        public bool UpdateDocumentEntity(IVfDocumentModel model, VfSpeaker.Data.DataStore.VfDocumentRow row)
        {
            row.Title = model.Title;
            row.Author = model.Author;
            row.Genre = model.Genre;
            row.Group = model.Group;
            row.Year = model.Year;
            row.Comments = model.Comments;
            row.AudioDirectory = model.AudioDirectory;
            row.Image = Convert.ToBase64String(model.Image);
            row.FileIndex = model.FileIndex;

            return true;
        }
예제 #4
0
 /// <summary>
 /// Builds the document model.
 /// </summary>
 /// <param name="row">The row.</param>
 /// <returns>VfDocumentModel.</returns>
 public VfDocumentModel BuildDocumentModel(VfSpeaker.Data.DataStore.VfDocumentRow row)
 {
     return new VfDocumentModel()
     {
         Id = row.Id,
         Title = row.Title,
         Author = row.Author,
         Genre = row.Genre,
         Group = row.Group,
         Year = row.Year,
         Comments = row.Comments,
         AudioDirectory = row.AudioDirectory,
         Image = Convert.FromBase64String(row.Image),
         FileIndex = row.FileIndex
     };
 }