cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject RE: [RT]: InputModules interfaces
Date Tue, 08 Oct 2002 09:17:00 GMT
Quoting Carsten Ziegeler <>:

> Hmm, is it the responsibility of the InputModule to filter?
> Or is it rather the calling component which gets information
> from an InputModule that should filter?
> And how would you apply this filter, let's say in the sitemap?
> Or is it a configuration thing?

hm... you are right. instead of providing the filter itself we
could provide the filter name and have filter components.

Object getAttribute( String name, Map objectModel, String[] filters) throws 

...just rethinking: we don't need filter chaining but applying
multiple filters. this way it's easy to do...

interface Filter extends Component {
  Object filter( Object input ) throws FilterException;

WildcardFilter implements Filter, ThreadSafe, Configurable {


  Object filter( Object input ) throws FilterException {


   <component-instance class="...WildcardFilter" name="id">
   <component-instance class="...RegExprFilter" name="id2">

 Object value = module.getAttribute( String name, Map objectModel, null)

 or with a filter

 Object value = module.getAttribute( String name, Map objectModel,
    new Filter[] { "id" }

This should also be incorparated into the the request logicsheet, too

What do you guys think?

To unsubscribe, e-mail:
For additional commands, email:

View raw message