Does one need to create multiple aliased object tags when dealing with
reflexive relationships?
Example: Consider a content management system site tree made up of nodes
(directories) and pages (files). A node may contain other nodes
(children) as well as pages.
Here's a base snippet of my reactor.xml
<object name="tblSiteTree" alias="Node">
<hasMany name="Page">
<relate from="intNodeID" to="intNodeID"></relate>
</hasMany>
</object>
<object name="tblPages" alias="Page">
<hasOne name="Node">
<relate from="intNodeID" to="intNodeID"></relate>
</hasOne>
</object>
How do I denote that a Node hasMany child nodes and hasOne parent?
Something like this?
<object name="tblSiteTree" alias="Node">
<hasMany name="Page">
<relate from="intNodeID" to="intNodeID"></relate>
</hasMany>
</object>
<object name="tblSiteTree" alias="Parent">
<hasMany name="Child">
<relate from="intNodeID" to="intNodeID"></relate>
</hasMany>
</object>
<object name="tblSiteTree" alias="Child">
<hasOne name="Parent">
<relate from="intNodeID" to="intNodeID"></relate>
</hasOne>
</object>
-B
_____
Brian Panulla
The IST Solutions Institute
Penn State College of Information Sciences and Technology
http://ist.psu.edu
-- Reactor for ColdFusion Mailing List -- [email protected]
-- Archives at http://www.mail-archive.com/reactor%40doughughes.net/