include "bufio.m";
include "lexicon.m";
lexicon := load Lexicon Lexicon->PATH;
open: fn(addr: string): (ref Lex, string);
fopen: fn(fd: ref Sys->FD): (ref Lex, string);
Lex: adt {
lexicons: fn(l: self ref Lex): (list of (string, string), string);
strategies: fn(l: self ref Lex): (list of (string, string), string);
serverinfo: fn(l: self ref Lex): (string, string);
lexiconinfo: fn(l: self ref Lex, lexicon: string):
(string, string);
match: fn(l: self ref Lex, word, lexicon, strategy: string):
(list of (string, string), string);
define: fn(l: self ref Lex, word, lexicon: string):
(list of (string, string, string, string), string);
setdebug: fn(l: self ref Lex, debug: int);
};
For match and define special values for lexicon are recognized (by the dict server): ``!'' for querying all databases until a match has been found, and ``*'' for querying all databases and continuing even when matches have been found.
``A Dictionary Server Protocol'', rfc2229.
| LEXICON(2 ) | Rev: Wed Oct 31 21:58:07 GMT 2007 |