Knowledge

Krauss wildcard-matching algorithm

Source 📝

64:. The experience tuning the single while loop using the profiler prompted development of a two-loop strategy that achieved further performance gains, particularly in situations involving empty input strings or input containing no wildcard characters. The two-loop algorithm is available for use by the 55:
The algorithm is based on a history of development, correctness and performance testing, and programmer feedback that began with an unsuccessful search for a reliable non-recursive algorithm for matching wildcards. An initial algorithm, implemented in a single while loop, quickly prompted comments
88:
and portable C++ (implemented without pointers). The test case code, also available under the Apache license, can be applied to any algorithm that provides the pattern matching operations below. The implementation as coded is unable to handle
56:
from software developers, leading to improvements. Ongoing comments and suggestions culminated in a revised algorithm still implemented in a single while loop but refined based on a collection of
169:
code library. It has been posted on GitHub in modified form as part of a log file reader. The 2014 algorithm is part of the Unreal Model Viewer built into the Epic Games
393: 359: 302: 266: 61: 105:
A one-to-one match is performed between the pattern and the source to be checked for a match, with the exception of asterisk (
81: 287: 216: 251: 43:
mechanism for matching patterns in software applications, based on syntax simpler than that typically offered by
90: 36: 236: 271: 221: 65: 413: 321: 93:
and poses problems when the text being searched may contain multiple incompatible character sets.
375: 190: 44: 29: 387: 353: 341: 33: 185: 25: 17: 166: 69: 407: 170: 173: 146:
matches any string that begins with "mini" (including the string "mini" itself).
80:
The algorithm made available under the Apache license is implemented in both
57: 40: 162: 195: 85: 124: 120:) character matches any sequence of zero or more characters. 110: 267:"Matching Wildcards: An Empirical Way to Tame an Algorithm" 101:
The algorithm supports three pattern matching operations:
288:"Matching Wildcards: An Improved Algorithm for Big Data" 117: 106: 165:programming language by Larry Heiges for use with 303:"Text compare function - generalTextCompare.txt" 161:The original algorithm has been ported to the 72:v. 2.0, and is accompanied by test case code. 68:development community, under the terms of the 8: 152:matches any string of three or more letters. 392:: CS1 maint: numeric names: authors list ( 358:: CS1 maint: numeric names: authors list ( 127:) character matches any single character. 207: 385: 380:Unreal Engine Model Viewer (UE Viewer) 351: 346:Unreal Engine Model Viewer (UE Viewer) 7: 140:matches any string containing "foo". 322:"Deniskore/wildcard/CLogReader.cpp" 252:"wild card matching in text string" 376:"History for UModel/Core/Core.cpp" 307:Data Access Worldwide Code Library 217:"Matching Wildcards: An Algorithm" 22:Krauss wildcard-matching algorithm 14: 39:, the algorithm provides a non- 1: 113:) characters in the pattern. 239:. alt.os.development. 2008. 97:Pattern matching operations 32:in common use, e.g. in the 430: 290:. Develop for Performance. 91:multibyte character sets 28:algorithm. Based on the 342:"UModel/Core/Core.cpp" 301:Heiges, Larry (2008). 37:command-line interface 286:Krauss, Kirk (2018). 265:Krauss, Kirk (2014). 237:"wild card searching" 215:Krauss, Kirk (2008). 167:Data Access Worldwide 326:Popular repositories 109:) or question mark ( 66:open-source software 62:performance profiler 45:regular expressions 320:Deniskore (2013). 272:Dr. Dobb's Journal 222:Dr. Dobb's Journal 191:glob (programming) 254:. Stack Overflow. 123:A question mark ( 34:Microsoft Windows 421: 398: 397: 391: 383: 374:gildor2 (2016). 371: 365: 363: 357: 349: 340:gildor2 (2016). 337: 331: 329: 317: 311: 310: 298: 292: 291: 283: 277: 276: 262: 256: 255: 247: 241: 240: 233: 227: 226: 212: 186:pattern matching 26:pattern matching 18:computer science 429: 428: 424: 423: 422: 420: 419: 418: 404: 403: 402: 401: 384: 373: 372: 368: 350: 339: 338: 334: 319: 318: 314: 300: 299: 295: 285: 284: 280: 264: 263: 259: 249: 248: 244: 235: 234: 230: 214: 213: 209: 204: 182: 159: 134: 99: 78: 53: 30:wildcard syntax 12: 11: 5: 427: 425: 417: 416: 406: 405: 400: 399: 366: 364:Lines 334-435. 332: 330:Lines 173-279. 312: 293: 278: 257: 242: 228: 206: 205: 203: 200: 199: 198: 193: 188: 181: 178: 158: 155: 154: 153: 147: 141: 133: 130: 129: 128: 121: 114: 98: 95: 77: 74: 70:Apache License 52: 49: 13: 10: 9: 6: 4: 3: 2: 426: 415: 412: 411: 409: 395: 389: 381: 377: 370: 367: 361: 355: 347: 343: 336: 333: 327: 323: 316: 313: 308: 304: 297: 294: 289: 282: 279: 274: 273: 268: 261: 258: 253: 250:T.J. (2014). 246: 243: 238: 232: 229: 224: 223: 218: 211: 208: 201: 197: 194: 192: 189: 187: 184: 183: 179: 177: 175: 172: 171:Unreal Engine 168: 164: 156: 151: 148: 145: 142: 139: 136: 135: 131: 126: 122: 119: 116:An asterisk ( 115: 112: 108: 104: 103: 102: 96: 94: 92: 87: 83: 75: 73: 71: 67: 63: 59: 50: 48: 46: 42: 38: 35: 31: 27: 23: 19: 379: 369: 345: 335: 325: 315: 306: 296: 281: 270: 260: 245: 231: 220: 210: 160: 157:Applications 149: 143: 137: 100: 79: 54: 21: 15: 174:game engine 414:Algorithms 202:References 58:test cases 348:. GitHub. 328:. GitHub. 41:recursive 408:Category 388:cite web 354:cite web 180:See also 163:DataFlex 132:Examples 196:wildmat 84:-based 82:pointer 51:History 60:and a 20:, the 144:mini* 138:*foo* 76:Usage 24:is a 394:link 360:link 150:???* 86:C++ 16:In 410:: 390:}} 386:{{ 378:. 356:}} 352:{{ 344:. 324:. 305:. 269:. 219:. 176:. 47:. 396:) 382:. 362:) 309:. 275:. 225:. 125:? 118:* 111:? 107:*

Index

computer science
pattern matching
wildcard syntax
Microsoft Windows
command-line interface
recursive
regular expressions
test cases
performance profiler
open-source software
Apache License
pointer
C++
multibyte character sets
*
?
*
?
DataFlex
Data Access Worldwide
Unreal Engine
game engine
pattern matching
glob (programming)
wildmat
"Matching Wildcards: An Algorithm"
Dr. Dobb's Journal
"wild card searching"
"wild card matching in text string"
"Matching Wildcards: An Empirical Way to Tame an Algorithm"

Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.