wcmatch
wcmatch
wcmatch(stringa: stringa, pattern: stringa) → nil
Esegue un pattern match tra stringa e pattern. Pattern può contenere *=quals.car - [abc]=da 'a' a 'c'
Le stringhe in ingresso possono essere sia standard LUA 4 che unicode.
wcmatch('prov123', 'prov*') -- ritorna 1
Esempio 1. Esempio wcmatch
-- * = qualsiasi sequenza, # = cifra singola, ? = carattere singolo
local ok = wcmatch("BIELLA-01", "BIELLA-#*")
if ok then print("\ncorrisponde") end