Take a look at the web.xml:

    <!--
      This parameter allows you to select the parent component manager.
      The class will be instantiated via the constructor that takes a
single
      String as a parameter. That String will be equal to the text after
the
      '/'.

      Cocoon honors the Loggable and Initializable interfaces for this
class,
      if it implements them.

      If you uncomment the following lines the parent CM is set to the
Parent CM sample, which will look up
      a configuration via JNDI at
org/apache/cocoon/samples/parentcm/ParentCMConfiguration
      and use it.
    <init-param>
      <param-name>parent-component-manager</param-name>
 
<param-value>org.apache.cocoon.samples.parentcm.ParentComponentManager/o
rg/apache/cocoon/samples/parentcm/ParentCMConfiguration</param-value>
    </init-param>
    -->

Might be of help to you.

Vadim

> From: Pierre-Alexandre Losson [mailto:[EMAIL PROTECTED]]
> 
> Hi folks,
> 
> Since Cocoon2 is based on Avalon & Excalibur, how do I use
> cocoon's component manager in the custom java classes used in a
web-app.
> 
> I saw that a "manager" handle was available in an XSP, but how do I
access
> the
> component manager from a pure java class I wrote myself ?
> 
> I think I can modify the cocoon.roles file, add a configuration entry
> in cocoon.xconf so that cocoon will initialize my component for me and
that
> way I will have access to it's component manager but this seems not
very
> "clean" to me
> 
> Is there any other way to do this ?
> 
> Pierre
> 


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to