|
Boost Users : |
From: Mohan gupta (mohangupta13_at_[hidden])
Date: 2008-04-24 10:56:05
thank you sir for your reply ..can you please tell me where can i get
the complete documentation or preferably tutorials on boost filesystem
??
i googled a lot and even on the boost filesystem official site i
cudn't get much .
yours thankfully
mohan gupta
On 4/24/08, Brad <boost_at_[hidden]> wrote:
>
> Mohan gupta wrote:
> > hello every one,
> > can anyone please tell me is there any way to find the files in a
> > directory with some exension say .txt,.doc, .cpp etc ......and then
> > use them ????
> > all help is appreciated
> > mohan gupta
> namespace bfs=boost::filesystem;
>
> bfs::path p("/home/user/folder");
> bfs::directory_iterator dir_iter(p), dir_end;
> for(;dir_iter != dir_end; ++dir_iter)
> {
> if( bfs::extension(*dir_iter) == ".txt" )
> do_something();
> elseif( bfs::extension(*dir_iter) == ".doc" )
> do_something_different();
> }
>
> For the most part not my code :-)
>
> Cheers,
> Brad
>
>
>
>
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net