model-view-controller

What are the alternatives to MVC architecture for web development? [duplicate]

落爺英雄遲暮 提交于 2019-12-20 19:36:23
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Alternatives to the MVC I have searched around for alternatives just to see what is available, but I can hardly find anything. I've read in many articles that web MVC is never true MVC for some reasons too technical for me to really grasp. And it is sometimes suggested to look for something else, but what are the something elses, what are the other architecture types? Where can i read more about it? Can someone

MVC Frameworks for WPF

大城市里の小女人 提交于 2019-12-20 14:14:50
问题 Are there any MVC frameworks available for WPF other than Caliburn (which looks awesome btw)? 回答1: Both Caliburn and PRISM are very nice. However if you go down the path of MVC you will miss out on the powerful 2 way binding. Consider MVVM, it's a very clean and practical approach for WPF. This is the pattern Microsoft used for their expression blend. 回答2: There is also Magellan, a port of ASP.NET MVC for WPF. 回答3: There is Composite WPF aka PRISM from Microsoft Pattern & Practices. http:/

MVC on the command line

拜拜、爱过 提交于 2019-12-20 14:00:44
问题 I am looking into the MVC from a Command line point of view (not web and no framework).. nice and simple. the only thing that confuses me is the View part of this? (well it may not be the only but its the main one) from the IBM site the view has the following definition The view provides the presentation of the model. It is the look of the application. The view can access the model getters, but it has no knowledge of the setters. In addition, it knows nothing about the controller. The view

MVC on the command line

非 Y 不嫁゛ 提交于 2019-12-20 13:59:00
问题 I am looking into the MVC from a Command line point of view (not web and no framework).. nice and simple. the only thing that confuses me is the View part of this? (well it may not be the only but its the main one) from the IBM site the view has the following definition The view provides the presentation of the model. It is the look of the application. The view can access the model getters, but it has no knowledge of the setters. In addition, it knows nothing about the controller. The view

Page Render Time in MVC

丶灬走出姿态 提交于 2019-12-20 13:19:32
问题 Q: How do I calculate the total time it takes to render an MVC page and display the time on the master page. In Asp.net Web Form I created a Base page class like so: public class PageBase : System.Web.UI.Page { private DateTime startTime = DateTime.Now; private TimeSpan renderTime; public DateTime StartTime { set { startTime = value; } get { return startTime; } } public virtual string PageRenderTime { get { renderTime = DateTime.Now - startTime; return renderTime.Seconds + "." + renderTime

Page Render Time in MVC

痴心易碎 提交于 2019-12-20 13:19:26
问题 Q: How do I calculate the total time it takes to render an MVC page and display the time on the master page. In Asp.net Web Form I created a Base page class like so: public class PageBase : System.Web.UI.Page { private DateTime startTime = DateTime.Now; private TimeSpan renderTime; public DateTime StartTime { set { startTime = value; } get { return startTime; } } public virtual string PageRenderTime { get { renderTime = DateTime.Now - startTime; return renderTime.Seconds + "." + renderTime

What is the difference between DAL, DTO and DAO in a 3 tier architecture style including with MVC

可紊 提交于 2019-12-20 11:59:20
问题 Recently I was learning about ORM (Object Relational Mapping) and the 3 tier architecture style (presentation,business and data persistence ). If I understand correctly, I can separate the data persistence layer into DTO and DAO layer. I would like to understand, how the following parts works together in a data persistence layer. DAL (Data Access Layer) DTO (Data Transfer Object) DAO (Data Access Object) In a top of that I learnt that In larger applications MVC is the presentation tier only

JavaFX + Hibernate(JPA) persistence + Derby DB

痞子三分冷 提交于 2019-12-20 10:57:37
问题 I'm developing a Java desktop application and was really interested in use JavaFX. I'm planning to use an MVC architecture because I have had some experience with Java EE and the MVC model. I want to store data in a embedded derby database and use Hibernate as persistence layer but I can't find a great tutorial about implementing MVC with hibernate and JavaFX. I have created the persistence file but I am not sure how to make it work with JavaFX. In Java EE I inject EJB services or DAOs but

How To Write Unit Test For Method Returning JsonResult With RenderPartialViewToString?

巧了我就是萌 提交于 2019-12-20 10:57:23
问题 If you look at the example at this link: http://www.atlanticbt.com/blog/asp-net-mvc-using-ajax-json-and-partialviews/ How would one write a unit test for the JsonAdd method? I have a similar situation in my own code, but the RenderPartialViewToString errors when calling: ViewEngineResult viewResult = ViewEngines.Engines.FindPartialView I've tried different ways of trying to stub that call to no avail. Any help appreciated. Thanks. 回答1: Since ViewEninges is a static class, you can't mock it

Designing an MVC repository using ViewModels

家住魔仙堡 提交于 2019-12-20 10:47:15
问题 I want to create a repository class to separate out my data logic from my controllers. I am using a ViewModel to represent some data that will be filled with data from different tables. Here are some questions I have: For a method like GetAll() , do I return an IQueryable<MyViewModel> or IQueryable<Entity> ? If I return viewmodels, how do I cope with a GetAll() that pulls thousands of records? Do I create a constructor for my custom ViewModel class that takes the Entity as a parameter to do