gnuherds-app-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: webapp architecture


From: Davi Leal
Subject: Re: webapp architecture
Date: Mon, 19 May 2008 23:24:45 +0200
User-agent: KMail/1.9.7

Armen Baghumian wrote:
> > Note: Due to the lack of developers, we should concentrate the effort
> > on adding the new features.  Anyhow, of course, anyone can work in
> > what [s]he wants.
>
> I'll take a more deep look at the code, I want to check if it is
> possible to implement a tiny framework for GNUHerds or not. it seems
> the code is reuse abel and it will not take much time to do, I don't
> like to have three layers just for a controller but I culd be wrong.

You are welcome Armen.  The project is the sum of the contributions of lot of 
people: code or advices.


> > I agree with you we could replace the access control stuff at the top
> > of pages by a call to a class method which does the same thing
> > executing the same source code lines, so removing such code
> > duplication.  However that code is only a short "if". Adding a class
> > to manage it could add more complexity to the webapp than just adding
> > such "if" as is on top of pages.
>
> no I dont mean to call a method of a class but I suggest to do that as
> a hook or filter which runs before the main requested action, as far as
> this is depend on implementing that light weight framework, let me
> check that first, I'll come back with a real world solution.

Great. You are welcome.


> > > 5) Why not use only three layers to separate Logic and Presentation
> > > and have a Central model and glue them with a central controller?
> > > (I mean ModelViewController)
> >
> > Note that even CSS is not just one layer. CSS can be several layers
> > [2]. Let's not simply what is in nature complex.
>
> Let me ask this question in anther way.
> Is there any benefits to have 3 layers as controller?

IMHO, in the MVC pattern any Controller have:

 * An interface or "entry point".
 * A call to the View to show the information, "page builder".
 * A business logic.

We can keep all that in the same directory or organized in one directory for 
each concept.  At the end it would be the same code working in the same way!

I prefer have it separated but it is just my current personal opinion. I can 
be mistaken.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]