Steve, Thanks for your reply. A few more questions for you. See below.
--- Stephen McConnell <[EMAIL PROTECTED]> wrote: ... > If the eventsystem is a component then you would > typically declare this > as a dependency. It is also feasible to supply a > object via the context > although this is not recommended practice (using the > context constructor > arguments in the component profile) - > > e.g.: > > <context class="MyContextCLass"> > > <import name="avalon:home" key="base"/> > <entry key="location" value="Paris"/> > <entry key="special" class="MySpecialClass"> > <parameter>hello</parameter> > </entry> > </context> > > See also: > > http://jakarta.apache.org/avalon/excalibur/merlin/api/ > ... merlin/model/ContextDirective.html > 1. Who will provide the value of "avalon:home", the immediate container, or any enclosing one? Any significance of the characters of ':', '.', etc in the key, or it's just for readability? 2. In the customer container example (CustomContainer.xprofile), the context of key="merlin:container.manager" is imported. It's defined in the DefaultContainer's .xinfo file. How are these two are related? Obviously, I missed something here. 3. How to create and pass a complex value (ie, a user-defined object) in the profile? Possible at all? > > > >3. How do I configure a non-default component, > >preferrably outside the > > startup.xml file? > > > > You can do this (a) via reference, or (b) via > packaging: > > configuration reference > ----------------------- > > <container name=a-container"> > <component name="my-component" > class="MyComponentClass" > > <configuration > src="../config/bySpecialExternalConfiguration.xml"/> > </component> > </container> > 1. The "resource://" format works, for which the .xml file is stored in one of the .jar files. 2. What else format of the src attribute and where the .xml file located, relative to the defining .xml file? Steve, what I really was asking was this: is there a way to "import" a component defined somewhere else or defined later that provides a desired service? For instance, in my example application, can I import one view component in the startup.xml file? Ideally, I should be able to import a service provider if it's defined and found somewhere otherwise a default one will be used. > packaged configuration > ---------------------- > > Just include the configuration as an > <classname>.xconfig file > in the same package as the class. > > Cheers, Steve. > Thanks once again. Cheers, Albert ===== Regards, Albert __________________________________________________ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>