cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ralph Goers <Ralph.Go...@digitalinsight.com>
Subject RE: Generic component and cocoon
Date Mon, 08 Mar 2004 18:05:11 GMT
I think the answer to your question is yes, you can.  I have several
components that I have created.  You define them in cocoon.xconf and perhaps
cocoon.roles.  Take a look at how input modules are done.

Ralph

 -----Original Message-----
From: 	Oscar Picasso [mailto:oscgoogle@yahoo.com] 
Sent:	Monday, March 08, 2004 9:50 AM
To:	cocoon list
Subject:	Generic component and cocoon

Hi,

Is it possible to write generic components but make them available only to
the
sitemap container for reuse by sitemap components?

Let's give an example.

I have a DefaultPathProvider with a provide(String partialPath) methods that
returns a complete default path from a partial path.

It is configured with an xml file like this one:

<path-step name="book" default="geography">

  <path-step name="history" default="middle-age">
    ...
  </path-step>

  <path-step name="geography" default="europe">
    <path-step name="america" default="...">
      ...
    </path-step>
    <path-step name="europe" default="italy">
      <path-step name="germany"/>
      <path-step name="france"/>
      <path-step name="italy"/>
      <path-step name="spain"/>
      ...
    </path-step>
    ...
  </path-step>

</path-step>


Once configured with the above xml file, the provide method would return the
following results.

provide("/book") --> "/book/geography/europe/italy"
provide("/book/geography") --> "/book/geography/europe/italy"
provide("/book/geography/europe") --> "/book/geography/europe/italy"

provide("/book/history") --> "/book/history/middle-age/..."

I would like this kind of component to be managed by the sitemap level
service
manager, to make it available to the serviceable components of the same
sitemap?

Does it make sense? Are they some examples of code in the cocoon
distribution
that use a similar approach?

Let me know if I am completly wrong on the way of developping generic
component
and use them in cocoon.

Thanks.

Oscar

__________________________________
Do you Yahoo!?
Yahoo! Search - Find what you're looking for faster
http://search.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message