cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <>
Subject Re: Component vs. ComponentSelector (or Service vs. ServiceSelector)
Date Fri, 06 May 2005 16:39:44 GMT
Joerg Heinicke wrote:
> Hello,
> whenever I try to lookup my component I get a ClassCastException when I want to
> cast it to the component's class.

Does your component implementation implements Component interface? Try if it 
does not.


> This is probably due to the intermediate
> selector one needs(?), but I don't know exactly. I just don't want to have the
> additional selector as there is just one implementation. And from my searches
> [1] and comparisons with existing Cocoon code [2] I got the feeling it must be
> possible without selectors. Is it? And how must the "thing" be set up (roles
> file + xconf)?
> Thanks in advance,
> Joerg
> [1] (In the
> example the result of the lookup is directly casted. Furthermore the text sounds
> like the selector being optional.)
> [2]
> java/org/apache/cocoon/forms/flow/javascript/Form.js?rev=158761&view=markup (The
> lookup result of FormManager.ROLE or BindingManager.ROLE is directly casted to
> FormManager or BindingManager. Though its flow script here, in the method in
> FOM_Cocoon nothing else is done than manager.lookup(String). The same is true
> for the javaflow example at
> java/org/apache/cocoon/forms/flow/java/

View raw message