private QuoteDM Map(QuoteSM quote) { QuoteDM phrase = new QuoteDM(); phrase.QuoteId = quote.QuoteId.ToString(); phrase.Phrase = quote.Phrase; phrase.Author = quote.Author; phrase.Category = quote.CategoryNum.ToString(); phrase.Rating = quote.RatingNum.ToString(); phrase.NumRatings = quote.NumRatings.ToString(); phrase.RatingScore = quote.RatingScore.ToString(); return(phrase); }
private QuoteSM Map(QuoteDM quote) { QuoteSM phrase = new QuoteSM(); phrase.QuoteId = Convert.ToInt32(quote.QuoteId); phrase.Phrase = quote.Phrase; phrase.Author = quote.Author; phrase.CategoryNum = Convert.ToInt32(quote.Category); phrase.RatingNum = Convert.ToInt32(quote.Rating); phrase.NumRatings = Convert.ToInt32(quote.NumRatings); phrase.RatingScore = Convert.ToInt32(quote.RatingScore); return(phrase); }