Blog.Logic.ObjectMapper.PostContentMapper.ToDto C# (CSharp) Method

ToDto() public static method

public static ToDto ( Blog.DataAccess.Database.Entities.Objects postContent ) : PostContent
postContent Blog.DataAccess.Database.Entities.Objects
return PostContent
        public static PostContent ToDto(Db.PostContent postContent)
        {
            return postContent == null ? null : 
                new PostContent
                {
                    Id = postContent.PostContentId,
                    PostId = postContent.PostId,
                    Media = postContent.Media == null ? null : MediaMapper.ToDto(postContent.Media),
                    PostContentText = postContent.PostContentText,
                    PostContentTitle = postContent.PostContentTitle,
                    CreatedBy = postContent.CreatedBy,
                    CreatedDate = postContent.CreatedDate,
                    ModifiedBy = postContent.ModifiedBy,
                    ModifiedDate = postContent.ModifiedDate
                };
        }
PostContentMapper