Question about the conroller:
In the controller layer of Forta's example
(PublicationController.cfc), he has a block of script that sets the
instance parameters values as follows:
<cfscript>
article.setTitle(form.title);
article.setTeaser(form.teaser);
article.setBody(form.body);
article.setAuthor(form.author);
if (article.getID() eq 0) {
article.create();
} else {
article.update();
}
</cfscript>
I am assuming he left the set methods out of the model layer for
breavity sake. Is it wise/necessary/required to create a set method
for every parameter that is passed to the method?
On 5/29/06, Nathan Drury <[EMAIL PROTECTED]> wrote:
> Hi Aaron
>
> This is a bit old now but the principles still apply -
> http://www.benorama.com/coldfusion/patterns/part2.htm I think Benoit does a
> good job of explaining MVC in CF terms.
>
> Cheers
>
> Nathan
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:241716
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54