I've sketched out a few options and am looking for opinions. Read end of email
for copy of the two options.
I think the Option 2 allows more flexibility, but will be better implemented if
the typenames are unique. So what this means is if you are going to extend
dmHTML instead of creating another dmHTML which extends the core dmHTML and
placing in your project directory, you create a myprefixHTML which extends
dmHTML and include the XML file.
This would allow you to then extend myprefixHTML with anotherprefixHTML.
Also, rather than having one mammoth XML file would it be better to have
smaller XML files? This would then allow you to just drop some files into the
project directory and it would just work, rather than having to paste something
into the XML file (think .
Also, I think the framework should error when it loads two XML files that
extend the same component.
Also for two level inheritance, which situation would be most given comAA
extends comA, and comAAA extends comAA and somebody does a "createObject
('type','comA'):
1) returns a comAAA (checks for futher extensions to comA's extension)
2) returns a comAA (doesn't check for further extension)
=== Option 1 (more generic) ===
API:
<cfscript>
oNav = application.factory.cfcFactory.createObject
("component","farcry.farcry_core.types.dmNavigation");
</cfscript>
XML:
<farcry_component_extensions>
<extension>
<path>farcry.farcry_core.types.dmNavigation</path>
<extension_path type="project">tlNavigation</extension_path>
</extension>
<extension>
<path>farcry.farcry_core.types.dmHTML</path>
<extension_path
type="absolute">com.toolmantim.packages.types.tlHTML</extension_path>
</extension>
<farcry_component_extensions>
=== Option 2 (more farcry specific) ===
API:
<cfscript>
oNav = application.factory.cfcFactory.createObject
("type","dmNavigation");
</cfscript>
XML:
<farcry_component_extensions>
<extension>
<type>type</type>
<name>dmNavigation</name>
<extension path="project">tlNavigation</extension>
</extension>
<extension>
<type>type</type>
<name>dmHTML</name>
<extension
type="absolute">com.toolmantim.packages.types.tlHTML</extension>
</extension>
<extension>
<type>type</type>
<core>
<farcry_component_extensions>
-- tim lucas
http://www.toolmantim.com
-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/
---
You are currently subscribed to farcry-dev as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/