예제 #1
0
 public forumVoteDTO(Int64 idVote, Nullable<Int64> idForumPost, Nullable<Int64> idPerson, Nullable<DateTime> date, String comment, String ip, forumPostDTO forumPost, personDTO person)
 {
     this.idVote = idVote;
     this.idForumPost = idForumPost;
     this.idPerson = idPerson;
     this.date = date;
     this.comment = comment;
     this.ip = ip;
     this.forumPost = forumPost;
     this.person = person;
 }
예제 #2
0
 public forumPostDTO(Int64 idForumPost, Nullable<Int64> idSubcategory, Nullable<Int64> idPerson, Nullable<Int64> parent_post, String title, String content_forum, Nullable<DateTime> date, String ip, List<forumPostDTO> forumPosts1, forumPostDTO forumPost1, forumSubcategoryDTO forumSubcategory, personDTO person, List<forumVoteDTO> forumVotes)
 {
     this.idForumPost = idForumPost;
     this.idSubcategory = idSubcategory;
     this.idPerson = idPerson;
     this.parent_post = parent_post;
     this.title = title;
     this.content_forum = content_forum;
     this.date = date;
     this.ip = ip;
     this.forumPosts1 = forumPosts1;
     this.forumPost1 = forumPost1;
     this.forumSubcategory = forumSubcategory;
     this.person = person;
     this.forumVotes = forumVotes;
 }
예제 #3
0
        /// <summary>
        /// Converts this instance of <see cref="forumPost"/> to an instance of <see cref="forumPostDTO"/>.
        /// </summary>
        /// <param name="entity"><see cref="forumPost"/> to convert.</param>
        public static forumPostDTO ToDTO(this forumPost entity)
        {
            if (entity == null) return null;

            var dto = new forumPostDTO();

            dto.idForumPost = entity.idForumPost;
            dto.idSubcategory = entity.idSubcategory;
            dto.idPerson = entity.idPerson;
            dto.parent_post = entity.parent_post;
            dto.title = entity.title;
            dto.content_forum = entity.content_forum;
            dto.date = entity.date;
            dto.ip = entity.ip;

            entity.OnDTO(dto);

            return dto;
        }
예제 #4
0
        /// <summary>
        /// Invoked when <see cref="ToDTO"/> operation is about to return.
        /// </summary>
        /// <param name="dto"><see cref="forumPostDTO"/> converted from <see cref="forumPost"/>.</param>
partial         static void OnDTO(this forumPost entity, forumPostDTO dto);