Documentation Project 1
ContentsIndexHome
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.
}
Copyright (c) 2010. All rights reserved.
What do you think about this topic? Send feedback!