[Catalyst] Re: Catalyst Digest, Vol 4, Issue 6

Justin Tocci jtocci at tocci.org
Mon Jun 6 19:24:31 CEST 2005


> Am 06.06.2005 um 17:25 schrieb Justin Tocci:
>
>> This is exactly what I'm saying. Ideally, the controller should go
>> to a different component to get the business logic, where all the
>> business logic and only the business logic lives. I don't want this
>> to get political, so... consider the example below.
>>
>
> What exactly do you mean with "business logic"?

Whatever is left over after making your components generic and  
completely reusable. Back to the "title on the list page" example,  
business logic is the code that would determine what the title is by  
the table name, or set the title manually by assignment.

> Actually it looks like you want to build a Maypole like application
> based on Catalyst,
> which provides a big n messy config file for "business logic",

Ugh. Don't know Maypole well enough to answer that but I hope not.

> something we all know (and hate) from the Java world... do i
> misunderstand?

Kind of works like a Java config file, I guess. *cringe*

Format would not be the same though. Would be more like this:

Rule 1:
--> variable needing value
   --> priority level
     --> scope (under what conditions does this rule count)
       --> logic to use to determine value (expression) OR manually  
set value ($name='John')

Rule 2: etc...

First the rules would be searched for which rules concern the  
variable in hand, of those, the highest priority rule would be  
checked for scope. If the scope was true, then the logic in that rule  
would determine the value for that variable and the controller would  
move on, if not, the next highest priority rule would be checked for  
scope, etc... until done.

Some would likely refer to it as big n messy I'm sure. I think it  
could be implemented neatly but that's me.

justin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rawmode.org/pipermail/catalyst/attachments/20050606/f859c2d4/attachment.htm


More information about the Catalyst mailing list