java ee MVC pattern, does model and view communicate directly with each other -


i'm learning java ee following book "java ee 7 big picture".

in book, author had picture illustrate mvc pattern in java ee.

enter image description here

as can see, in figure, model , view directly communicating each other.

but understand of mvc (i first learned mvc pattern ios development) model , view should never communicate directly each other. communication between model , view should done through controller (i.e. controller act interpreter between model , view).

so diagram flawed? or correct, , need re-adjust understanding of mvc pattern java ee way?

thanks!

the diagram doesn't seem helpful. in javaee controller accept form filled out user, doing validation, hand off data service layer update, redirect controller fetches new updated object (the model) , adds request request attribute, forwarding template generates html. view sort of template knows model in request attributes. model doesn't know tell view anything, typically far view concerned model data container , nothing more.


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -