Ejemplo n.º 1
0
        public virtual BOComments MapEFToBO(
            Comments ef)
        {
            var bo = new BOComments();

            bo.SetProperties(
                ef.Id,
                ef.CreationDate,
                ef.PostId,
                ef.Score,
                ef.Text,
                ef.UserId);
            return(bo);
        }
        public virtual BOComments MapModelToBO(
            int id,
            ApiCommentsRequestModel model
            )
        {
            BOComments boComments = new BOComments();

            boComments.SetProperties(
                id,
                model.CreationDate,
                model.PostId,
                model.Score,
                model.Text,
                model.UserId);
            return(boComments);
        }