Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
390 views
in Technique[技术] by (71.8m points)

php - Is ZF2 based on MOVE?

I'm wondering if ZF2 is based entierly on MOVE instead of the classic MVC.

Somewhere I read that is really bases on MOVE (http://cirw.in/blog/time-to-move-on) but e.g. in the "getting started tutorial" (http://zf2.readthedocs.org/en/latest/user-guide/overview.html) they are saying "creating a simple database driven application using the Model-View-Controller paradigm".

So, what is it now based on? Does it support both?

I'm a bit confused. What are the difference at MVC between ZF1 and ZF2?

Thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
MOVE (Models, Operations, Views and Events)
MVC (Models, Views, Controllers)

The problem with MVC is that you end up stuffing too much code into controllers, to overcome this problem MOVE is another possible option to choose in zf2 projects, Because in this architecture you can split your controller into Events and Operations.

Question: Is ZF2 based entirely on the MOVE architecture?

I don't think ZF2 is designed entirely on MOVE architecture. ZF2 follows the SOLID object oriented design principle with loosely coupled MVC architecture which provide more flexibility in terms of usability.

Question: Can I develop my projects using the MOVE architecture in ZF2?

Yes ZF2 provides you with everything to support both architectures (MOVE, MVC). It provides Models, Views, Controllers(Operations), Events. It is up to the developer which architecture he would like to use.

ZF1 and ZF2 is compared in another thread.

MVC or MOVE

SOLID Object Oriented Programing


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...