Exemplo n.º 1
0
        public virtual ApiDirectTweetResponseModel MapBOToModel(
            BODirectTweet boDirectTweet)
        {
            var model = new ApiDirectTweetResponseModel();

            model.SetProperties(boDirectTweet.TweetId, boDirectTweet.Content, boDirectTweet.Date, boDirectTweet.TaggedUserId, boDirectTweet.Time);

            return(model);
        }
Exemplo n.º 2
0
        public virtual BODirectTweet MapEFToBO(
            DirectTweet ef)
        {
            var bo = new BODirectTweet();

            bo.SetProperties(
                ef.TweetId,
                ef.Content,
                ef.Date,
                ef.TaggedUserId,
                ef.Time);
            return(bo);
        }
Exemplo n.º 3
0
        public virtual DirectTweet MapBOToEF(
            BODirectTweet bo)
        {
            DirectTweet efDirectTweet = new DirectTweet();

            efDirectTweet.SetProperties(
                bo.Content,
                bo.Date,
                bo.TaggedUserId,
                bo.Time,
                bo.TweetId);
            return(efDirectTweet);
        }
Exemplo n.º 4
0
        public virtual BODirectTweet MapModelToBO(
            int tweetId,
            ApiDirectTweetRequestModel model
            )
        {
            BODirectTweet boDirectTweet = new BODirectTweet();

            boDirectTweet.SetProperties(
                tweetId,
                model.Content,
                model.Date,
                model.TaggedUserId,
                model.Time);
            return(boDirectTweet);
        }