Gateway: A CFC that contains SQL for selecting or deleting multiple rows from one or several database tables.

Transfer Object: An object that, in general, carries instance data in its THIS scope instead of in it's variables scope. It often has a validate() method to make sure the data is valid, but it in general it can be looked upon as "a struct on steroids" and is generally used to pass data from, for example, a controller into a DAO to write data to the databse, or a controller may set a TO based on data from a  DAO into an event object for display in a view (eg: arguments.event.setValue("outputData",ReactorRecord.getTo())).

You can sort of think of a TO as one of those South American tree frogs that carries a million little baby frogs around on it's back until they're big enough to go out on their own... a VO (or Value Object) is sorta the same thing, though it may be more like a marsupial in that it has a generic accessor (like setValue()) but still keeps everything in the variables scope whereas the TO has all it's data in THIS and a bean has all its data in it's variables scope and discreet get/set methods for each value.

Is that the sort of thing you're looking for Dan?

Thanks,
J


------------------------------------------------

Jared C. Rypka-Hauer

Continuum Media Group LLC

http://www.web-relevant.com

Member, Team Macromedia - ColdFusion


"That which does not kill me makes me stranger." - Yonah Schmeidler


On Feb 21, 2006, at 12:51 PM, Daniel Short wrote:

Hi Ken, 

You might want to check out Sean's Mach-II Development Guide 
(or at least bookmark it.) I found it quite helpful when 
first approaching OO. It's a good overview of MVC as well as 
event-driven architecture. And yes, I did have to read it 
many, many times before things started to really sink in. ;) 


I've been through that once I think :), and had many of the language issues
that I still have. Just simply not understanding a concept wrapped up in a
single phrase (Gateway Object, Transfer Object, etc.)

Don't get hung up on the syntax if you aren't going to use 
Mach-II (though knowing more than one framework is always a 
Good Thing.) The concepts are what you're after. 

Definitely, thanks for the reminder though :)

Of course, there's always Sun's Core J2EE Patterns page, 
which is sure to give you a nosebleed, but is also worth bookmarking.


Not sure Daniel-san's ready for that yet :).

Dan





-- Reactor for ColdFusion Mailing List -- [email protected]



Reply via email to