コード例 #1
0
        public static RestuarantReviewDataLayer.Reviewer LibraryToData(RestaurantLibrary.Models.Reviewer libraryReviewer)
        {
            var dataModel = new RestuarantReviewDataLayer.Reviewer()
            {
                name  = libraryReviewer.name,
                email = libraryReviewer.email
            };

            return(dataModel);
        }
コード例 #2
0
        // parameter is the EF Restuarant model
        public static RestaurantLibrary.Models.Reviewer DataToLibrary(RestuarantReviewDataLayer.Reviewer reviewer)
        {
            var libModel = new RestaurantLibrary.Models.Reviewer()
            {
                name  = reviewer.name,
                email = reviewer.email
            };

            return(libModel);
        }