コード例 #1
0
 public static UserComment ToUserComment(this d.MovieCommentEntity comment)
 {
     return(new UserComment()
     {
         Id = comment.Id,
         Title = comment.Title,
         Content = comment.Content,
         Value = comment.Value,
         MovieTitle = comment.MovieTitle,
         MovieId = comment.MovieId,
         Created_at = comment.Created_at
     });
 }
コード例 #2
0
 public static MovieComment ToMovieComment(this d.MovieCommentEntity comment)
 {
     return(new MovieComment()
     {
         Id = comment.Id,
         Title = comment.Title,
         Content = comment.Content,
         Value = comment.Value,
         Login = comment.Login,
         UserId = comment.UserId,
         Created_at = comment.Created_at
     });
 }
コード例 #3
0
 //****Mappers for multiple Comments models from DAL to API****
 public static CompleteComment ToApi(this d.MovieCommentEntity comment)
 {
     return(new CompleteComment()
     {
         Id = comment.Id,
         Title = comment.Title,
         Content = comment.Content,
         Value = comment.Value,
         MovieTitle = comment.MovieTitle,
         Login = comment.Login,
         MovieId = comment.MovieId,
         UserId = comment.UserId,
         Created_at = comment.Created_at
     });
 }