You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by jhair <js...@yahoo.com> on 2006/10/20 03:40:39 UTC

File filtering with FilePoller

Is there a way to configure the FilePoller to read only files that match a
pattern? For example, read files in 'input' directory that have an extension
of '.csv'?

Thanx,
jsh
-- 
View this message in context: http://www.nabble.com/File-filtering-with-FilePoller-tf2477373.html#a6908960
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: File filtering with FilePoller

Posted by Guillaume Nodet <gn...@gmail.com>.
You can configure the filter property of the FilePoller.

   <bean class="o.a.s.components.file.FilePoller">
     <property name="filter">
       <bean ... />
     </property>
   </bean>

You can use http://jakarta.apache.org/oro/api/org/apache/oro/io/RegexFilenameFilter.html
(or one of its derived class) or implement your own java.io.FileFilter.

On 10/20/06, jhair <js...@yahoo.com> wrote:
>
> Is there a way to configure the FilePoller to read only files that match a
> pattern? For example, read files in 'input' directory that have an extension
> of '.csv'?
>
> Thanx,
> jsh
> --
> View this message in context: http://www.nabble.com/File-filtering-with-FilePoller-tf2477373.html#a6908960
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet