cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vadim.gritse...@verizon.net>
Subject RE: Howto: call an internal pipeline from a component
Date Tue, 12 Feb 2002 15:38:34 GMT
> From: Michael Gerzabek [mailto:michael.gerzabek@at.efp.cc]
> 
> Hello!
> 
> I need to call an internal pipeline from a component that's working
> in the background.
> try {
>   String source = "cocoon://i-post-XRFC/" + conf.getAttribute("name")
+ "/"
> + conf.getAttribute("type") + "/" + id;
>   URLFactory urlFactory = (URLFactory)manager.lookup(URLFactory.ROLE);

"cocoon:" is not a protocol, it's *pseudo* protocol.


>   URL url = this.urlFactory.getURL(source);
>   ...
> 
> and then I get
> java.net.MalformedURLException: unknown protocol: cocoon
> 	at java.net.URL.<init>(URL.java:480)
> 	at java.net.URL.<init>(URL.java:376)
> 	at java.net.URL.<init>(URL.java:330)
> 	at
>
org.apache.cocoon.components.url.URLFactoryImpl.getURL(URLFactoryImpl.ja
va:6
> 6)
> 
> Is there a way to do so?

You have to have resolver. Then:

Source source = resolver.resolve("cocoon://i-post-XRFC/.....");

Vadim

> 
> - Michael
> 


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


Mime
View raw message