Strings

Str module

The str module contains string manipulation utilities such as upper/lower case conversion, trimming, computing substrings and string search.

MODULE str;

COMMAND str.ascii(X_0:str):int;
COMMENT "";

COMMAND str.endsWith(X_0:str, X_1:str):bit;
COMMENT "";

COMMAND str.epilogue():void;
COMMENT "";

COMMAND str.insert(X_0:str, X_1:int, X_2:int, X_3:str):str;
COMMENT "";

COMMAND str.length(X_0:str):int;
COMMENT "";

COMMAND str.like(X_0:str, X_1:str):bit;
COMMENT "";

COMMAND str.like3(X_0:str, X_1:str, X_2:str):bit;
COMMENT "";

COMMAND str.locate(X_0:str, X_1:str):int;
COMMENT "";

COMMAND str.locate3(X_0:str, X_1:str, X_2:int):int;
COMMENT "";

COMMAND str.lpad(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.lpad3(X_0:str, X_1:int, X_2:str):str;
COMMENT "";

COMMAND str.ltrim(X_0:str):str;
COMMENT "";

COMMAND str.ltrim2(X_0:str, X_1:str):str;
COMMENT "";

COMMAND str.nbytes(X_0:str):int;
COMMENT "";

COMMAND str.prefix(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.prelude():void;
COMMENT "";

COMMAND str.r_search(X_0:str, X_1:str):int;
COMMENT "";

COMMAND str.repeat(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.replace(X_0:str, X_1:str, X_2:str, X_3:str):str;
COMMENT "";

COMMAND str.replace(X_0:str, X_1:str, X_2:str):str;
COMMENT "";

COMMAND str.rpad(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.rpad3(X_0:str, X_1:int, X_2:str):str;
COMMENT "";

COMMAND str.rtrim(X_0:str):str;
COMMENT "";

COMMAND str.rtrim2(X_0:str, X_1:str):str;
COMMENT "";

COMMAND str.search(X_0:str, X_1:str):int;
COMMENT "";

COMMAND str.space(X_0:int):str;
COMMENT "";

COMMAND str.splitpart(X_0:str, X_1:str, X_2:int):str;
COMMENT "";

COMMAND str.startsWith(X_0:str, X_1:str):bit;
COMMENT "";

COMMAND str.str(X_0:str):str;
COMMENT "";

COMMAND str.string(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.string3(X_0:str, X_1:int, X_2:int):str;
COMMENT "";

COMMAND str.stringleft(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.stringright(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.substitute(X_0:str, X_1:str, X_2:str, X_3:bit):str;
COMMENT "";

COMMAND str.substring(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.substring3(X_0:str, X_1:int, X_2:int):str;
COMMENT "";

COMMAND str.suffix(X_0:str, X_1:int):str;
COMMENT "";

COMMAND str.toLower(X_0:str):str;
COMMENT "";

COMMAND str.toUpper(X_0:str):str;
COMMENT "";

COMMAND str.trim(X_0:str):str;
COMMENT "";

COMMAND str.trim2(X_0:str, X_1:str):str;
COMMENT "";

COMMAND str.unicode(X_0:int):str;
COMMENT "";

COMMAND str.unicodeAt(X_0:str, X_1:int):int;
COMMENT "";

Batstr module

MODULE batstr;

PATTERN batstr.ascii(X_0:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.ascii(X_0:bat[:str], X_1:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.endsWith(X_0:bat[:str], X_1:bat[:str]):bat[:bit];
COMMENT "";

PATTERN batstr.endsWith(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.endsWith(X_0:str, X_1:bat[:str]):bat[:bit];
COMMENT "";

PATTERN batstr.endsWith(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.endsWith(X_0:bat[:str], X_1:str):bat[:bit];
COMMENT "";

PATTERN batstr.endsWith(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.insert(X_0:bat[:str], X_1:bat[:int], X_2:bat[:int], X_3:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.insert(X_0:bat[:str], X_1:int, X_2:int, X_3:str):bat[:str];
COMMENT "";

PATTERN batstr.length(X_0:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.length(X_0:bat[:str], X_1:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:bat[:str], X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:str, X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:bat[:str], X_1:str):bat[:int];
COMMENT "";

PATTERN batstr.locate(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.locate3(X_0:bat[:str], X_1:bat[:str], X_2:bat[:int]):bat[:int];
COMMENT "";

PATTERN batstr.locate3(X_0:bat[:str], X_1:str, X_2:int):bat[:int];
COMMENT "";

PATTERN batstr.lpad(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.lpad(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.lpad(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.lpad(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.lpad(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.lpad(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.lpad3(X_0:bat[:str], X_1:bat[:int], X_2:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.lpad3(X_0:bat[:str], X_1:bat[:int], X_2:str):bat[:str];
COMMENT "";

PATTERN batstr.lpad3(X_0:bat[:str], X_1:int, X_2:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.lpad3(X_0:bat[:str], X_1:int, X_2:str):bat[:str];
COMMENT "";

PATTERN batstr.ltrim(X_0:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim(X_0:bat[:str], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:str, X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:bat[:str], X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:bat[:str], X_1:str):bat[:str];
COMMENT "";

PATTERN batstr.ltrim2(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.nbytes(X_0:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.nbytes(X_0:bat[:str], X_1:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:bat[:str], X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:str, X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:bat[:str], X_1:str):bat[:int];
COMMENT "";

PATTERN batstr.r_search(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.repeat(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.repeat(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.repeat(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.repeat(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.repeat(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.repeat(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.replace(X_0:bat[:str], X_1:bat[:str], X_2:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.replace(X_0:bat[:str], X_1:str, X_2:str):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.rpad(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rpad3(X_0:bat[:str], X_1:bat[:int], X_2:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.rpad3(X_0:bat[:str], X_1:bat[:int], X_2:str):bat[:str];
COMMENT "";

PATTERN batstr.rpad3(X_0:bat[:str], X_1:int, X_2:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.rpad3(X_0:bat[:str], X_1:int, X_2:str):bat[:str];
COMMENT "";

PATTERN batstr.rtrim(X_0:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim(X_0:bat[:str], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:str, X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:bat[:str], X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:bat[:str], X_1:str):bat[:str];
COMMENT "";

PATTERN batstr.rtrim2(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.search(X_0:bat[:str], X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.search(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.search(X_0:str, X_1:bat[:str]):bat[:int];
COMMENT "";

PATTERN batstr.search(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.search(X_0:bat[:str], X_1:str):bat[:int];
COMMENT "";

PATTERN batstr.search(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.space(X_0:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.space(X_0:bat[:int], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.splitpart(X_0:bat[:str], X_1:bat[:str], X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.splitpart(X_0:bat[:str], X_1:bat[:str], X_2:int):bat[:str];
COMMENT "";

PATTERN batstr.splitpart(X_0:bat[:str], X_1:str, X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.splitpart(X_0:bat[:str], X_1:str, X_2:int):bat[:str];
COMMENT "";

PATTERN batstr.startsWith(X_0:bat[:str], X_1:bat[:str]):bat[:bit];
COMMENT "";

PATTERN batstr.startsWith(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.startsWith(X_0:str, X_1:bat[:str]):bat[:bit];
COMMENT "";

PATTERN batstr.startsWith(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.startsWith(X_0:bat[:str], X_1:str):bat[:bit];
COMMENT "";

PATTERN batstr.startsWith(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:bit];
COMMENT "";

PATTERN batstr.string(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.string(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.string(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.string(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.string(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.string(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.stringleft(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.stringright(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substitute(X_0:bat[:str], X_1:bat[:str], X_2:bat[:str], X_3:bat[:bit]):bat[:str];
COMMENT "";

PATTERN batstr.substitute(X_0:bat[:str], X_1:str, X_2:str, X_3:bit):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:bat[:str], X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:str, X_1:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:bat[:str], X_1:int):bat[:str];
COMMENT "";

PATTERN batstr.substring(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:bat[:int], X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:bat[:int], X_2:bat[:int], X_3:bat[:oid], X_4:bat[:oid], X_5:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:int, X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:int, X_2:bat[:int], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:bat[:int], X_2:int):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:bat[:int], X_2:int, X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:bat[:int], X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:str, X_1:bat[:int], X_2:bat[:int], X_3:bat[:oid], X_4:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:int, X_2:int):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:int, X_2:int, X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:int, X_2:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:int, X_2:bat[:int], X_3:bat[:oid], X_4:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:bat[:int], X_2:int):bat[:str];
COMMENT "";

PATTERN batstr.substring3(X_0:bat[:str], X_1:bat[:int], X_2:int, X_3:bat[:oid], X_4:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.toLower(X_0:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.toLower(X_0:bat[:str], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.toUpper(X_0:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.toUpper(X_0:bat[:str], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.trim(X_0:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.trim(X_0:bat[:str], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:str, X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:str, X_1:bat[:str], X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:bat[:str], X_1:bat[:str]):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:bat[:str], X_1:bat[:str], X_2:bat[:oid], X_3:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:bat[:str], X_1:str):bat[:str];
COMMENT "";

PATTERN batstr.trim2(X_0:bat[:str], X_1:str, X_2:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.unicode(X_0:bat[:int]):bat[:str];
COMMENT "";

PATTERN batstr.unicode(X_0:bat[:int], X_1:bat[:oid]):bat[:str];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:bat[:str], X_1:bat[:int]):bat[:int];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:bat[:str], X_1:bat[:int], X_2:bat[:oid], X_3:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:str, X_1:bat[:int]):bat[:int];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:str, X_1:bat[:int], X_2:bat[:oid]):bat[:int];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:bat[:str], X_1:int):bat[:int];
COMMENT "";

PATTERN batstr.unicodeAt(X_0:bat[:str], X_1:int, X_2:bat[:oid]):bat[:int];
COMMENT "";

PCRE module

The PCRE module is a set of functions that implement regular expression pattern matching using the same syntax and semantics as Perl, with just a few differences. The current implementation of PCRE (release 4.x) corresponds approximately with Perl 5.8, including support for UTF-8 encoded strings. To use this module the server has to be compiled with the pcre library.

MODULE pcre;

COMMAND pcre.imatch(X_0:str, X_1:str):bit;
COMMENT "";

COMMAND pcre.index(X_0:pcre, X_1:str):int;
COMMENT "";

COMMAND pcre.match(X_0:str, X_1:str):bit;
COMMENT "";

COMMAND pcre.patindex(X_0:str, X_1:str):int;
COMMENT "";

COMMAND pcre.pcre_quote(X_0:str):str;
COMMENT "";

COMMAND pcre.prelude():void;
COMMENT "";

COMMAND pcre.replace(X_0:str, X_1:str, X_2:str, X_3:str):str;
COMMENT "";

COMMAND pcre.replace_first(X_0:str, X_1:str, X_2:str, X_3:str):str;
COMMENT "";

COMMAND pcre.sql2pcre(X_0:str, X_1:str):str;
COMMENT "";

Batpcre module

MODULE batpcre;

COMMAND batpcre.replace(X_0:bat[:str], X_1:str, X_2:str, X_3:str):bat[:str];
COMMENT "";

COMMAND batpcre.replace_first(X_0:bat[:str], X_1:str, X_2:str, X_3:str):bat[:str];
COMMENT "";

TXTSIM module

The txtsim module provides similarity metrics for strings.

MODULE txtsim;

COMMAND txtsim.editdistance(X_0:str, X_1:str):int;
COMMENT "";

COMMAND txtsim.editdistance2(X_0:str, X_1:str):int;
COMMENT "";

COMMAND txtsim.levenshtein(X_0:str, X_1:str, X_2:int, X_3:int, X_4:int):int;
COMMENT "";

COMMAND txtsim.levenshtein(X_0:str, X_1:str):int;
COMMENT "";

COMMAND txtsim.qgramnormalize(X_0:str):str;
COMMENT "";

COMMAND txtsim.qgramselfjoin(X_0:bat[:oid], X_1:bat[:oid], X_2:bat[:int], X_3:bat[:int], X_4:flt, X_5:int) (X_6:bat[:int], X_7:bat[:int]);
COMMENT "";

COMMAND txtsim.similarity(X_0:str, X_1:str):dbl;
COMMENT "";

COMMAND txtsim.similarity(X_0:str, X_1:str, X_2:dbl):dbl;
COMMENT "";

COMMAND txtsim.soundex(X_0:str):str;
COMMENT "";

COMMAND txtsim.str2qgrams(X_0:str):bat[:str];
COMMENT "";

COMMAND txtsim.stringdiff(X_0:str, X_1:str):int;
COMMENT "";

Battxtsim module

MODULE battxtsim;

COMMAND battxtsim.similarity(X_0:bat[:str], X_1:bat[:str]):bat[:dbl];
COMMENT "";

Tokenizer module

MODULE tokenizer;

COMMAND tokenizer.append(X_0:str):oid;
COMMENT "";

COMMAND tokenizer.close():void;
COMMENT "";

COMMAND tokenizer.depositFile(X_0:str):void;
COMMENT "";

COMMAND tokenizer.getCardinality():bat[:lng];
COMMENT "";

COMMAND tokenizer.getCount():bat[:lng];
COMMENT "";

COMMAND tokenizer.getIndex():bat[:oid];
COMMENT "";

COMMAND tokenizer.getLevel(X_0:int):bat[:str];
COMMENT "";

PATTERN tokenizer.locate(X_0:str):oid;
COMMENT "";

COMMAND tokenizer.open(X_0:str):void;
COMMENT "";

PATTERN tokenizer.take(X_0:oid):str;
COMMENT "";