|
-
April 12th, 2007, 10:25 AM
#1
Is there a standard C++ wildcard filter / matcher class?
If I am looking through a list of files in a directory using OpenDir(), I want to be able to do wild card pattern matches.
Under Microsoft's MFC you can specify this with FindFiles like "BA*12??.*.DA*" or something crazy like that. Using the ANSI equivalent, OpenDir() I can't do that.
I could write my own wild-card filter, but I would rather use something pre-made instead.
-
April 12th, 2007, 11:19 AM
#2
Re: Is there a standard C++ wildcard filter / matcher class?
Hi,
no, such thing does not exist in the standard C libraries. You might want to use boost´s RegEx library.
Boost
Regards,
Guido
- Guido
-
April 12th, 2007, 02:27 PM
#3
Re: Is there a standard C++ wildcard filter / matcher class?
I would suggest using both boost::filesystem and boost::regex. They are both portable and powerful.
Jeff
-
April 12th, 2007, 03:47 PM
#4
Re: Is there a standard C++ wildcard filter / matcher class?
I was looking at the License am not totally sure what it means. Can I use that code in a commercial product that isn't open source for free?
-
April 12th, 2007, 04:04 PM
#5
Re: Is there a standard C++ wildcard filter / matcher class?
Yes. You can use it, change it, redistribute it. It can be used in open source and commercial projects. It's a completely open license that is much more relaxed than GPL, for instance. It does not contain the gnu open source 'virus'.
Jeff
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|