Sack Library Documentation
ContentsIndexReferenceHome
PreviousUpNext
sack::filesys::CompareMask Function
C++
FILESYS_PROC int FILESYS_API CompareMask(CTEXTSTR mask, CTEXTSTR name, int keepcase);
Parameters 
Description 
CTEXTSTR mask 
This is the mask used to compare 
CTEXTSTR name 
this is the name to compare against using the mask. 
int keepcase 
if TRUE, must match case also. 

TRUE if name is matched by mask. Otherwise returns FALSE.

The mask support standard 'globbing' characters. 

? matches one character 

* matches 0 or more characters 

otherwise the literal character must match, unless comparing case insensitive, in which case 'A' == 'a' also.

if( CompareMask( "*.exe", "program.exe", FALSE ) )
{
    // then program.exe is matched by the mask.
}
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at support@toolsfactory.com.
Copyright (c) 2000+. All rights reserved.
What do you think about this topic? Send feedback!